Closed zixulll closed 1 year ago
Hello @zixulll ,
This is because of the pytorch version - monodepth2 used an older version of pytorch.
Specifically, the pytorch API for data augment you mentioned changed since ver 1.7.0 (I remember), consider downgrade your pytorch if you do want to use the original monodepth2 code, or simply change the code for data augmentation (it is not too hard).
Hello @zixulll ,
This is because of the pytorch version - monodepth2 used an older version of pytorch.
Specifically, the pytorch API for data augment you mentioned changed since ver 1.7.0 (I remember), consider downgrade your pytorch if you do want to use the original monodepth2 code, or simply change the code for data augmentation (it is not too hard).
If you are still not sure about what to do, I'll offer you the specific code tomorrow.
Hello @xingyuuchen Thank you for your prompt reply. My work is carried out based on Monodepth2. I happened to notice that your paper included an experiment to add loss based on monodepth2, but I encountered some bugs during my attempts and still couldn't solve them. If it's convenient, could you please provide the code related to monodepth2? Thank you.
For the data loader in monodepth2, you can simply refer to my another repo, i.e. here.
Thank you for your enthusiastic reply! The problem has now been successfully resolved.
Thank you for your enthusiastic reply! The problem has now been successfully resolved.
My pleasure. Hope your work goes well :)
Your outstanding work is amazing. I tried to use your proposed loss for monodepth2, but there are always bugs when importing data, can you provide the code for monodepth2 about kitti_dataset and mono_datasets, thank you.
Original Traceback (most recent call last): File "/home/yzhang/anaconda3/envs/mono/lib/python3.8/site-packages/torch/utils/data/_utils/worker.py", line 202, in _worker_loop data = fetcher.fetch(index) File "/home/yzhang/anaconda3/envs/mono/lib/python3.8/site-packages/torch/utils/data/_utils/fetch.py", line 44, in fetch data = [self.dataset[idx] for idx in possibly_batched_index] File "/home/yzhang/anaconda3/envs/mono/lib/python3.8/site-packages/torch/utils/data/_utils/fetch.py", line 44, in
data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/yzhang/monodepth2-master/datasets/kitti_dataset.py", line 176, in getitem
self.preprocess(inputs, color_aug)
File "/home/yzhang/monodepth2-master/datasets/kitti_dataset.py", line 121, in preprocess
self.a=color_aug(f)
TypeError: 'tuple' object is not callable