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

        if not isinstance(obj, dict):
            return DockerWorkerConfigV4.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 DockerWorkerConfigV4) in the input: " + str(obj))

        _obj = DockerWorkerConfigV4.parse_obj({
            "worker_type": obj.get("workerType"),
            "docker": DockerWorkerConfigV4Docker.from_dict(obj.get("docker")) if obj.get("docker") is not None else None,
            "lightly": DockerWorkerConfigV3Lightly.from_dict(obj.get("lightly")) if obj.get("lightly") is not None else None,
            "selection": SelectionConfigV4.from_dict(obj.get("selection")) if obj.get("selection") is not None else None
        })
        return _obj
Create an instance of DockerWorkerConfigV4 from a dict
lightly/openapi_generated/swagger_client/models/docker_worker_config_v4.py