You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
class CR_LoadImageList:
....
# Ensure start_index is within the bounds of the list
start_index = max(0, min(start_index, len(file_list) - 1))
# Calculate the end index based on max_rows
end_index = min(start_index + max_images, len(file_list) - 1)
for num in range(start_index, end_index):
img = Image.open(os.path.join(in_path, file_list[num]))
image = img.convert("RGB")
image_list.append(pil2tensor(image))
'range(start_index, end_index):'
this not include 'end_index' , so
' end_index = min(start_index + max_images, len(file_list) - 1) should change ' len(file_list) - 1' to ' len(file_list)' '
The text was updated successfully, but these errors were encountered:
'range(start_index, end_index):'
this not include 'end_index' , so
' end_index = min(start_index + max_images, len(file_list) - 1) should change ' len(file_list) - 1' to ' len(file_list)' '
The text was updated successfully, but these errors were encountered: