Skip to content

But in layers.cpp #38

Description

@erlebach

Hi,

In layer.py, class FeaturesEmbedding, one finds the line

self.offsets = np.array(0, *np.cumsum(field_dims)[:-1]), dtype=np.long)

My code generates an error. I replaced np.array by torch.tensor and np.cumsum by torch.cumsum , and the code works.

I believe the code as it is has a bug, which was fixed with my change. Could you please confirm this? I am not sure how the code can work as is. thanks.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions