Skip to content

NestedField modifies the attribute include_lengths of the NestingField #357

Open
@kent930

Description

@kent930

Hi,
The methods pad() and numericalize() of NestedField set the attribute include_lengths of the NestingField to True after the first call to the NestedField.

This introduces an inconsistent behaviour since I'm also using the NestingField with the attribute include_lengths=False as another field and it returns a tensor for the first call and then a tuple.

Is there a reason for that, or should this parameter be replaced by its original value after the padding (like fix length for example, self.nesting_field.fix_length = old_fix_len).

Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions