geowatch.cli.coco_remove_bad_images module

class geowatch.cli.coco_remove_bad_images.CocoRemoveBadImagesConfig(*args, **kwargs)[source]

Bases: DataConfig

Remove coco images that are mostly nodata. Can also delete the on-disk assets if specified.

Valid options: []

Parameters:
  • *args – positional arguments for this data config

  • **kwargs – keyword arguments for this data config

default = {'channels': <Value(None)>, 'delete_assets': <Value('auto')>, 'dst': <Value(None)>, 'interactive': <Value(True)>, 'mode': <Value('process')>, 'overview': <Value(0)>, 'src': <Value('data.kwcoco.json')>, 'workers': <Value(0)>}
geowatch.cli.coco_remove_bad_images.main(cmdline=True, **kwargs)[source]
geowatch.cli.coco_remove_bad_images.compute_asset_disk_usage(dset, gids, mode, workers)[source]
geowatch.cli.coco_remove_bad_images.is_image_empty(coco_img, main_channels=None, overview=-1)[source]

Run heristics to determine if a coco image is empty.

geowatch.cli.coco_remove_bad_images.find_empty_images(dset, main_channels, overview=-1, mode='process', workers=0)[source]