Search code examples
fiftyone

FiftyOne operator throw timeout error after 15 minutes


I am using FiftyOne operators to improve a dataset.
The exact operator I'm using is from here : https://github.com/jacobmarks/image-quality-issues

Here is my code :

def compute_image_quality(dataset, features_thresholds: dict):
    for feature in features_thresholds:
        if features_thresholds[feature]: 
            compute = foo.get_operator(f"@jacobmarks/image_issues/compute_{feature}")
            compute(dataset)
    dataset.save()

def main(datasets_list, features: dict): 
    for dataset_name in datasets_list:
        fo.load_dataset(dataset_name)
        compute_image_quality(fo.load_dataset(dataset_name), features)

It works for every datasets, except those who takes more than 15 minutes to be analyzed.
I couldn't find anything about setting timeout in function arguments neither in FiftyOne documentation.

I can't figure out if it's a issue with the plugin, FiftyOne of just a matter of configuration.


Solution

  • As you discovered, you can set the operator timeout in your FiftyOne Config as described here: https://docs.voxel51.com/user_guide/config.html#configuration-options.

    However, for longer-running operations like this, the recommended approach is to run the operator in delegated execution mode. You should still be able to queue the job via python, by passing delegate=True into the operator call. Then from the command line run:

    fiftyone delegated launch