JitengMu / Learning-from-Synthetic-Animals

Learning from Synthetic Animals (CVPR2020, oral)
GNU General Public License v3.0
63 stars 12 forks source link

IndexError: list index out of range #4

Closed wenwenzhanghaha123wonder closed 2 years ago

wenwenzhanghaha123wonder commented 2 years ago

File "CCSSL/CCSSL.py", line 364, in main() File "CCSSL/CCSSL.py", line 203, in main for i, ((src_img, src_lbl, src_meta), (trg_img, trg_lbl, trg_meta)) in enumerate(joint_loader): File "/usr/local/lib/python3.8/dist-packages/torch/utils/data/dataloader.py", line 435, in next data = self._next_data() File "/usr/local/lib/python3.8/dist-packages/torch/utils/data/dataloader.py", line 475, in _next_data data = self._dataset_fetcher.fetch(index) # may raise StopIteration File "/usr/local/lib/python3.8/dist-packages/torch/utils/data/_utils/fetch.py", line 44, in fetch data = [self.dataset[idx] for idx in possibly_batched_index] File "/usr/local/lib/python3.8/dist-packages/torch/utils/data/_utils/fetch.py", line 44, in data = [self.dataset[idx] for idx in possibly_batched_index]
File "/home/zww/code/Learning-from-Synthetic-Animals-master/CCSSL/scripts/ssl_datasets/ssl_real_animal_crop.py", line 209, in getitem pts = self.anno_list[self.train_list[index]] IndexError: list index out of range

The environment is set up, the data set and key points are put in, and the first training is carried out. This error is reported when the pseudo-label is generated. Why?

JitengMu commented 2 years ago

Have you downloaded the Tigdog dataset following the installation guide? I would check if the self.anno_list is loaded correctly.

Download and pre-processing datasets: Download TigDog Dataset and move folder behaviorDiscovery2.0 to ./animal_data. Run python get_cropped_TigDog.py to get cropped TigDog Dataset. Download Synthetic Animal Dataset with script bash get_dataset.sh.

wenwenzhanghaha123wonder commented 2 years ago

Thanks! The problem is solved, but the name of the cropped TigDog data set is wrong.