zhiwen-xdu/EventSAM

class Mix_RGBE_Encoder(nn.Module) BUG

Closed this issue · 2 comments

Hello, thank you for your open source code.
Maybe class Mix_RGBE_Encoder(nn.Module) has two BUGs in these two lines, one is self.image_encoder(input_images) only returns two variables, but you wrote three here, image_tokens are not mentioned. The other one is masks here are not declared cause code to run incorrectly. Can you solve it?

image_tokens, image_embeddings_dict, token_weights_dict = self.image_encoder(input_images)
evimg_embeddings_dict = self.evimg_encoder(input_evimgs,image_tokens,masks)

These code bugs have been addressed.

It seems that there are still problems with the code, for example image_tokens are not defined. Is it certain that this code is reproducible?

        input_images = self.image_preprocess(images)
        input_evimgs = self.evimg_preprocess(evimgs)
        image_embeddings_dict, token_weights_dict = self.image_encoder(input_images)
        evimg_embeddings_dict = self.evimg_encoder(input_evimgs,image_tokens)

        return image_embeddings_dict,evimg_embeddings_dict,token_weights_dict