HelloRicky123 / Siamese-RPN

Full reimplementation of siamese rpn, has 0.24 eao on vot2017.
MIT License
223 stars 44 forks source link

TypeError: a bytes-like object is required, not 'NoneType' #53

Closed Manguotree closed 5 years ago

Manguotree commented 5 years ago

Traceback (most recent call last): File "bin/train_siamrpn.py", line 14, in Fire(train) File "/home/yangli/anaconda3/envs/mm/lib/python3.5/site-packages/fire/core.py", line 138, in Fire component_trace = _Fire(component, args, parsed_flag_args, context, name) File "/home/yangli/anaconda3/envs/mm/lib/python3.5/site-packages/fire/core.py", line 471, in _Fire target=component.name) File "/home/yangli/anaconda3/envs/mm/lib/python3.5/site-packages/fire/core.py", line 675, in _CallAndUpdateTrace component = fn(*varargs, **kwargs) File "/home/yangli/zqw/zhu/Siamese-RPN-master/net/train.py", line 170, in train for i, data in enumerate(tqdm(trainloader)): File "/home/yangli/anaconda3/envs/mm/lib/python3.5/site-packages/tqdm/std.py", line 1091, in iter for obj in iterable: File "/home/yangli/anaconda3/envs/mm/lib/python3.5/site-packages/torch/utils/data/dataloader.py", line 637, in next return self._process_next_batch(batch) File "/home/yangli/anaconda3/envs/mm/lib/python3.5/site-packages/torch/utils/data/dataloader.py", line 658, in _process_next_batch raise batch.exc_type(batch.exc_msg) TypeError: Traceback (most recent call last): File "/home/yangli/anaconda3/envs/mm/lib/python3.5/site-packages/torch/utils/data/dataloader.py", line 138, in _worker_loop samples = collate_fn([dataset[i] for i in batch_indices]) File "/home/yangli/anaconda3/envs/mm/lib/python3.5/site-packages/torch/utils/data/dataloader.py", line 138, in samples = collate_fn([dataset[i] for i in batch_indices]) File "/home/yangli/zqw/zhu/Siamese-RPN-master/net/dataset.py", line 132, in getitem exemplar_img = self.imread(exemplar_name) File "/home/yangli/zqw/zhu/Siamese-RPN-master/net/dataset.py", line 57, in imread img_buffer = np.frombuffer(img_buffer, np.uint8) TypeError: a bytes-like object is required, not 'NoneType'

0%| | 0/1403 [00:13<?, ?it/s]

please help me!! thanks

cifar10 commented 5 years ago

perhaps,When you generated the lmdb file,you changed the name of the storage VID+Yotu_bb folder, resulting in the original path of the image not being read from the lmdb file.

Manguotree commented 5 years ago

perhaps,When you generated the lmdb file,you changed the name of the storage VID+Yotu_bb folder, resulting in the original path of the image not being read from the lmdb file.

thanks!! I found the problem, Maybe my video name in VID+Yotu_bb has been garbled after moving the number set