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

Input Tiles to RNN aren't ranked #22

Open
thewayofknowing opened this issue Aug 29, 2022 · 1 comment
Open

Input Tiles to RNN aren't ranked #22

thewayofknowing opened this issue Aug 29, 2022 · 1 comment

Comments

@thewayofknowing
Copy link

I was cross referencing the publication with the code here and I ran into a bit of inconsistency. From the RNN-based slide integration section -

Given a slide and model f, we can obtain a list of the S most interesting tiles within the slide in terms of positive class probability. The ordered sequence of vector representations e = e1, e2,…, eS is the input to an RNN along with a state vector h.

However, in the code the tiles are fed at random (if shuffled) or otherwise in no particular ranked order of class probabilities
Line 236 of RNN_train.py

    if self.shuffle:
        grid = random.sample(grid,len(grid))
    out = []
    s = min(self.s, len(grid))
    for i in range(s):
        img = slide.read_region(grid[i], self.level, (self.size, self.size)).convert('RGB')

Just a little clarification would be greatly appreciated

@aamster
Copy link

aamster commented Oct 3, 2022

Hi @thewayofknowing if I understand correctly the authors expect the input to the RNN to be filtered to the tiles with highest probability of positive class. So the code block is shuffling these top tiles. But I agree, then it is not ordered as quoted in the paper

Also the default for shuffle is False, which maybe means the authors didn't set to True

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

2 participants