Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

explore_latent_space possible index error for halfset 2 #14

Open
metteroes opened this issue Dec 11, 2024 · 1 comment
Open

explore_latent_space possible index error for halfset 2 #14

metteroes opened this issue Dec 11, 2024 · 1 comment

Comments

@metteroes
Copy link

Hi! I think I may have found a bug, at least it is for my purposes.

During the deformation, the dataset is split up into 3: A tenth is validation set and the remainder is then split into two equally sized sets, the two half sets - correct?

However, in explore_latent_space line 102-111, it seems that the indices for the second half set are found by subtracting the indices of the first half set from the full dataset. That means that the second half set now includes the validation set:

image

list(set(range(len(dataset))) - set(list(inds_half1))))

When I print out the size of the latent space, I do also get a larger array for half set 2 than half set 1. For the beta amylase dataset for example, I have 2127 rows/images for half set 1, and 2599 for half set 2.

@metteroes
Copy link
Author

This fixes it and has not caused me any other problems yet.

`elif half_set == 2:

    inds_half1 = cp['indices_half1'].cpu().numpy()
    inds_validation = cp['indices_val'].cpu().numpy()
    indices = np.asarray(
        list(set(range(len(dataset))) - set(list(inds_half1)) - set(list(inds_validation))))`

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant