Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[BUG] Dynamic field schema methods erroneously declare subfields of Polyline points #3183

Closed
brimoor opened this issue Jun 11, 2023 · 0 comments · Fixed by #3152
Closed

[BUG] Dynamic field schema methods erroneously declare subfields of Polyline points #3183

brimoor opened this issue Jun 11, 2023 · 0 comments · Fixed by #3152
Labels
bug Bug fixes

Comments

@brimoor
Copy link
Contributor

brimoor commented Jun 11, 2023

The snippet below:

import fiftyone as fo

dataset = fo.Dataset()
dataset.add_sample(
    fo.Sample(
        filepath="image.jpg",
        shapes=fo.Polylines(
            polylines=[
                fo.Polyline(
                    tags=['tag1', 'tag2'],
                    label='label1',
                    points=[[(0, 0), (0, 1), (1, 1), (1, 0), (0, 0)]]
                ),
            ]
        )
    )
)

dataset.get_dynamic_field_schema()

erroneously detects the following dynamic fields:

{
    'shapes.polylines.points[]': <fiftyone.core.fields.ListField object at 0x7f938808ac10>,
    'shapes.polylines.points[][][]': <fiftyone.core.fields.IntField object at 0x7f936824cdc0>,
}

I believe the fix here is that default list fields should not be inspected.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Bug fixes
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant