def from_dict(cls, obj: dict) -> CropData:
        """Create an instance of CropData from a dict"""
        if obj is None:
            return None

        if not isinstance(obj, dict):
            return CropData.parse_obj(obj)

        # raise errors for additional fields in the input
        for _key in obj.keys():
            if _key not in cls.__properties:
                raise ValueError("Error due to additional fields (not defined in CropData) in the input: " + str(obj))

        _obj = CropData.parse_obj({
            "parent_id": obj.get("parentId"),
            "prediction_uuid_timestamp": obj.get("predictionUUIDTimestamp"),
            "prediction_index": obj.get("predictionIndex"),
            "prediction_task_name": obj.get("predictionTaskName"),
            "prediction_task_category_id": obj.get("predictionTaskCategoryId"),
            "prediction_task_score": obj.get("predictionTaskScore")
        })
        return _obj
Create an instance of CropData from a dict
lightly/openapi_generated/swagger_client/models/crop_data.py