def test_input_labelstudio_image():
    """Test creation of LabelStudioImageClassificationInput from images."""
    download_data("https://label-studio-testdata.s3.us-east-2.amazonaws.com/lightning-flash/data_nofile.zip")

    data = {
        "data_folder": "data/upload/",
        "export_json": "data/project_nofile.json",
        "multi_label": True,
    }

    train_data, val_data = LabelStudioInput._split_train_val_data(data, split=0.2)
    train = LabelStudioImageClassificationInput(RunningStage.TRAINING, train_data)
    val = LabelStudioImageClassificationInput(RunningStage.VALIDATING, val_data, parameters=train.parameters)

    train_sample = train[0]
    val_sample = val[0]
    assert train_sample
    assert val_sample
Test creation of LabelStudioImageClassificationInput from images.
tests/core/integrations/labelstudio/test_labelstudio.py