We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
code for rtdetrv2_pytorch/src/data/dataloader.py
rtdetrv2_pytorch/src/data/dataloader.py
class BatchImageCollateFuncion(BaseCollateFunction): def __init__( self, scales=None, stop_epoch=None, ) -> None: super().__init__() self.scales = scales self.stop_epoch = stop_epoch if stop_epoch is not None else 100000000 # self.interpolation = interpolation def __call__(self, items): images = torch.cat([x[0][None] for x in items], dim=0) targets = [x[1] for x in items] if self.scales is not None and self.epoch < self.stop_epoch: # sz = random.choice(self.scales) # sz = [sz] if isinstance(sz, int) else list(sz) # VF.resize(inpt, sz, interpolation=self.interpolation) sz = random.choice(self.scales) images = F.interpolate(images, size=sz) if 'masks' in targets[0]: for tg in targets: tg['masks'] = F.interpolate(tg['masks'], size=sz, mode='nearest') raise NotImplementedError('') return images, targets
请问下训练之前随机选择size为sz大小进行插值,图像的size变化了,但是boxes没有做相应的变换,这样会不会存在boxes和size变换后的图像对不上的情况,请问下我理解的对嘛。谢谢您!
The text was updated successfully, but these errors were encountered:
但是boxes没有做相应的变换,这样会不会存在boxes和size变换后的图像对不上的情况,请问下我理解的对嘛。谢谢您!
本仓库里box到这一步已经归一化了, 图像resize不影响
Sorry, something went wrong.
但是boxes没有做相应的变换,这样会不会存在boxes和size变换后的图像对不上的情况,请问下我理解的对嘛。谢谢您! 本仓库里box到这一步已经归一化了, 图像resize不影响
明白,谢谢您!按照这样理解的话还是有点疑问。那数据做_transforms变换时为什么可以先resize后再做normal,而且normal时在resize的大小(640)上进行的,并没有按比例进行调整。希望您可以指点下迷津,感谢!
lyuwenyu
No branches or pull requests
code for
rtdetrv2_pytorch/src/data/dataloader.py
请问下训练之前随机选择size为sz大小进行插值,图像的size变化了,但是boxes没有做相应的变换,这样会不会存在boxes和size变换后的图像对不上的情况,请问下我理解的对嘛。谢谢您!
The text was updated successfully, but these errors were encountered: