Skip to content

an error occurs while packaging the training dataset for object-detection #19

@Geoyi

Description

@Geoyi

an error:
`Traceback (most recent call last):
File "/Users/xxxx/.virtualenvs/ml_data_gen_py3/bin/label-maker", line 11, in
load_entry_point('label-maker', 'console_scripts', 'label-maker')()
File "/Users/xxx/Documents/Development_Seed/Sat_Deeptrain/label-maker/label_maker/main.py", line 87, in cli
package_directory(dest_folder=dest_folder, **config)
File "/Users/xxx/Documents/Development_Seed/Sat_Deeptrain/label-maker/label_maker/package.py", line 48, in package_directory
for tile in tiles.files:
AttributeError: 'numpy.ndarray' object has no attribute 'files'
original codes over there are:

    if ml_type == 'object-detection':
        max_features = 0
        for tile in tiles.files:
            features = len(tiles[tile][0])
            if features > max_features:
                max_features = features

and fixed by

    if ml_type == 'object-detection':
        max_features = 0
        for tile in labels.files:
            features = len(labels[tile])
            if features > max_features:
                max_features = features

seems worked after the fixing, if I understood the workflow correctly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions