Skip to content

Utils/visualise can create an IndexError #15

@mikaelsimard5

Description

@mikaelsimard5

There is a potential issue in utils/visualise at line 43 where test_slice is defined:

test_slice = random.randint(0, val_data["image"].shape[4])

This will create an IndexError if test_slice == val_data["image"].shape[4].

The fix is to adjust randint:

test_slice = random.randint(0, val_data["image"].shape[4]-1)

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions