Wuziyi616 / SlotDiffusion

Code release for NeurIPS 2023 paper SlotDiffusion: Object-centric Learning with Diffusion Models
https://slotdiffusion.github.io/
MIT License
78 stars 7 forks source link

Training on COCO dataset #5

Closed sw-jang closed 10 months ago

sw-jang commented 10 months ago

Thanks for sharing your great work.

I am currently struggling to run training on COCO dataset using the command below.

CUDA_VISIBLE_DEVICES=0 python scripts/train.py --task img_based --params slotdiffusion/img_based/configs/sa_ldm/sa_ldm_dino_coco_params-res224.py --fp16 --cudnn

This is the error message I am currently experiencing.

Traceback (most recent call last): File "scripts/train.py", line 119, in main(params) File "scripts/train.py", line 76, in main method.fit( File "nerv/nerv/training/method.py", line 213, in fit self.validation_epoch( File "lib/python3.8/site-packages/torch/autograd/grad_mode.py", line 28, in decorate_context return func(*args, *kwargs) File "SlotDiffusion/slotdiffusion/img_based/method.py", line 67, in validation_epoch self._sample_img(model) File "lib/python3.8/site-packages/torch/autograd/grad_mode.py", line 28, in decorate_context return func(args, **kwargs) File "SlotDiffusion/slotdiffusion/img_based/method.py", line 372, in _sample_img {f'val/{k}': self._convert_img(v) File "SlotDiffusion/slotdiffusion/img_based/method.py", line 372, in {f'val/{k}': self._convert_img(v) File "SlotDiffusion/slotdiffusion/img_based/method.py", line 36, in _convert_img norm = dst.getattribute(f'{dst_name}_transforms').normalize AttributeError: 'COCOTransforms' object has no attribute 'normalize'

It would be very helpful if you share your opinion on the error.

Wuziyi616 commented 10 months ago

Hi thanks for pointing that out. I pushed a new fix. Let me know if the newest code works for you!