sequence_transformers.py 文件源码

python
阅读 17 收藏 0 点赞 0 评论 0

项目:keras-transform 作者: Dref360 项目源码 文件源码
def __getitem__(self, index):
        assert self.sequence, "This transformer {} has not been called with a Sequence object".format(
            self.__class__.__name__)
        batch = self.sequence[index]
        if self.batch_size is None:
            # The first batch should be the maximum batch_size i.e. not the last.
            self.batch_size = get_batch_size(batch)

        args = self.get_args()
        for arg in args:
            arg.update(self.common_args)

        return apply_fun(batch, self.apply_transformation, self.mask, transformation=self.transformation, args=args)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号