This issue is part of a Codex global repository scan.
Problem:
The Embedding(method="none") implementation calls torch.nn.Module.__init__ with extra arguments. It also exposes out_note_dim instead of out_node_dim, while NNENV reads self.embedding.out_node_dim when building SKTB prediction layers.
Code references:
https://github.com/deepmodeling/deeptb/blob/86c60c73996f0dd961c3138f2e88424382cb734e/dptb/nn/embedding/identity.py#L8-L24
https://github.com/deepmodeling/deeptb/blob/86c60c73996f0dd961c3138f2e88424382cb734e/dptb/nn/deeptb.py#L131-L143
Impact:
The none embedding path fails during model construction, and would still fail later with AttributeError even after the constructor is fixed.
Suggested fix:
Call super().__init__() without extra arguments and rename/add the property as out_node_dim.
This issue is part of a Codex global repository scan.
Problem:
The
Embedding(method="none")implementation callstorch.nn.Module.__init__with extra arguments. It also exposesout_note_diminstead ofout_node_dim, whileNNENVreadsself.embedding.out_node_dimwhen building SKTB prediction layers.Code references:
https://github.com/deepmodeling/deeptb/blob/86c60c73996f0dd961c3138f2e88424382cb734e/dptb/nn/embedding/identity.py#L8-L24
https://github.com/deepmodeling/deeptb/blob/86c60c73996f0dd961c3138f2e88424382cb734e/dptb/nn/deeptb.py#L131-L143
Impact:
The
noneembedding path fails during model construction, and would still fail later withAttributeErroreven after the constructor is fixed.Suggested fix:
Call
super().__init__()without extra arguments and rename/add the property asout_node_dim.