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
In the last forwrd part of CellPLM/CellPLM/embedder/omics.py, I notice that the pe variable is always initialized as 0 and it seems that pe not related the coordinate encoding. Does it mean that x only includes the expression embed and batch embed? Could you explain the reasons? Thanks.
def forward(self, x_dict, input_gene_list=None):
x = self.feat_enc(x_dict, input_gene_list)#self.act(self.feat_enc(x_dict, input_gene_list))
if self.pe_enc is not None:
pe_input = x_dict[self.pe_enc.pe_key]
pe = 0.#self.pe_enc(pe_input)
if self.inject_covariate:
pe = pe + self.cov_enc(x_dict['batch'])
if self.cat_pe:
x = torch.cat([x, pe], 1)
else:
x = x + pe
x = self.extra_linear(x)
# x = self.norm0(self.dropout(x))
return x
The text was updated successfully, but these errors were encountered:
Sorry for the late response. This is a bug for sure and I'm very sad that I didn't see this issue until today. This comment should definitely be removed in order to facilitate spatial transcriptomics. I'll fix it in an update soon.
https://github.com/OmicsML/CellPLM/blob/b59ee7688b1bd2a745856a610248b46f15019a22/CellPLM/embedder/omics.py#L88C1-L101C17
In the last forwrd part of
CellPLM/CellPLM/embedder/omics.py
, I notice that thepe
variable is always initialized as 0 and it seems thatpe
not related the coordinate encoding. Does it mean thatx
only includes the expression embed and batch embed? Could you explain the reasons? Thanks.The text was updated successfully, but these errors were encountered: