Open liuyisu opened 8 months ago
I have the same question. Have you solved it?
Generally speaking, this can be caused by the mismatch of file path, file name and mask suffix. If your original image is named in the form of ‘image_001.jpg’, when your mask file is named ‘image_001.png’, the mask_suffix is set to ’ ‘ (set to empty), if your mask file is named ‘image_001_mask.png’, please set mask_suffix to ‘_mask’, this may solve your problem!
PS D:\WICT\UNet\Pytorch-UNet-master> & E:/Anaconda/envs/u-net/python.exe d:/WICT/UNet/Pytorch-UNet-master/Pytorch-UNet-master/train.py INFO: Using device cpu INFO: Network: 3 input channels 2 output channels (classes) Transposed conv upscaling INFO: Creating dataset with 5088 examples INFO: Scanning mask files to determine unique values 0%| | 0/5088 [00:04<?, ?it/s] INFO: Creating dataset with 5088 examples INFO: Scanning mask files to determine unique values 0%| | 0/5088 [00:04<?, ?it/s] multiprocessing.pool.RemoteTraceback: """ Traceback (most recent call last): File "E:\Anaconda\envs\u-net\lib\multiprocessing\pool.py", line 125, in worker result = (True, func(*args, *kwds)) File "d:\WICT\UNet\Pytorch-UNet-master\Pytorch-UNet-master\utils\data_loading.py", line 27, in unique_mask_values mask_file = list(mask_dir.glob(idx + mask_suffix + '.'))[0] mask_file = list(mask_dir.glob(idx + mask_suffix + '.*'))[0] IndexError: list index out of range """ IndexError: list index out of range """
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
The above exception was the direct cause of the following exception:
Traceback (most recent call last):
Traceback (most recent call last):
File "d:/WICT/UNet/Pytorch-UNet-master/Pytorch-UNet-master/train.py", line 213, in
May I ask how to solve this problem?Thank you very much
May I ask how to solve this problem?Thank you very much