wallaroo.wallaroo_ml_ops_api_client.models.assays_get_baseline_json_body

  1from typing import Any, Dict, List, Type, TypeVar, Union
  2
  3import attr
  4
  5from ..types import UNSET, Unset
  6
  7T = TypeVar("T", bound="AssaysGetBaselineJsonBody")
  8
  9@attr.s(auto_attribs=True)
 10class AssaysGetBaselineJsonBody:
 11    """ Request to retrieve an assay baseline.
 12
 13    Attributes:
 14        pipeline_name (str):  Pipeline name.
 15        workspace_id (Union[Unset, None, int]):  Workspace identifier.
 16        start (Union[Unset, None, str]):  Start date and time.
 17        end (Union[Unset, None, str]):  End date and time.
 18        model_name (Union[Unset, None, str]):  Model name.
 19        limit (Union[Unset, None, int]):  Maximum number of baselines to return.
 20    """
 21
 22    pipeline_name: str
 23    workspace_id: Union[Unset, None, int] = UNSET
 24    start: Union[Unset, None, str] = UNSET
 25    end: Union[Unset, None, str] = UNSET
 26    model_name: Union[Unset, None, str] = UNSET
 27    limit: Union[Unset, None, int] = UNSET
 28    additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
 29
 30
 31    def to_dict(self) -> Dict[str, Any]:
 32        pipeline_name = self.pipeline_name
 33        workspace_id = self.workspace_id
 34        start = self.start
 35        end = self.end
 36        model_name = self.model_name
 37        limit = self.limit
 38
 39        field_dict: Dict[str, Any] = {}
 40        field_dict.update(self.additional_properties)
 41        field_dict.update({
 42            "pipeline_name": pipeline_name,
 43        })
 44        if workspace_id is not UNSET:
 45            field_dict["workspace_id"] = workspace_id
 46        if start is not UNSET:
 47            field_dict["start"] = start
 48        if end is not UNSET:
 49            field_dict["end"] = end
 50        if model_name is not UNSET:
 51            field_dict["model_name"] = model_name
 52        if limit is not UNSET:
 53            field_dict["limit"] = limit
 54
 55        return field_dict
 56
 57
 58
 59    @classmethod
 60    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
 61        d = src_dict.copy()
 62        pipeline_name = d.pop("pipeline_name")
 63
 64        workspace_id = d.pop("workspace_id", UNSET)
 65
 66        start = d.pop("start", UNSET)
 67
 68        end = d.pop("end", UNSET)
 69
 70        model_name = d.pop("model_name", UNSET)
 71
 72        limit = d.pop("limit", UNSET)
 73
 74        assays_get_baseline_json_body = cls(
 75            pipeline_name=pipeline_name,
 76            workspace_id=workspace_id,
 77            start=start,
 78            end=end,
 79            model_name=model_name,
 80            limit=limit,
 81        )
 82
 83        assays_get_baseline_json_body.additional_properties = d
 84        return assays_get_baseline_json_body
 85
 86    @property
 87    def additional_keys(self) -> List[str]:
 88        return list(self.additional_properties.keys())
 89
 90    def __getitem__(self, key: str) -> Any:
 91        return self.additional_properties[key]
 92
 93    def __setitem__(self, key: str, value: Any) -> None:
 94        self.additional_properties[key] = value
 95
 96    def __delitem__(self, key: str) -> None:
 97        del self.additional_properties[key]
 98
 99    def __contains__(self, key: str) -> bool:
100        return key in self.additional_properties
@attr.s(auto_attribs=True)
class AssaysGetBaselineJsonBody:
 10@attr.s(auto_attribs=True)
 11class AssaysGetBaselineJsonBody:
 12    """ Request to retrieve an assay baseline.
 13
 14    Attributes:
 15        pipeline_name (str):  Pipeline name.
 16        workspace_id (Union[Unset, None, int]):  Workspace identifier.
 17        start (Union[Unset, None, str]):  Start date and time.
 18        end (Union[Unset, None, str]):  End date and time.
 19        model_name (Union[Unset, None, str]):  Model name.
 20        limit (Union[Unset, None, int]):  Maximum number of baselines to return.
 21    """
 22
 23    pipeline_name: str
 24    workspace_id: Union[Unset, None, int] = UNSET
 25    start: Union[Unset, None, str] = UNSET
 26    end: Union[Unset, None, str] = UNSET
 27    model_name: Union[Unset, None, str] = UNSET
 28    limit: Union[Unset, None, int] = UNSET
 29    additional_properties: Dict[str, Any] = attr.ib(init=False, factory=dict)
 30
 31
 32    def to_dict(self) -> Dict[str, Any]:
 33        pipeline_name = self.pipeline_name
 34        workspace_id = self.workspace_id
 35        start = self.start
 36        end = self.end
 37        model_name = self.model_name
 38        limit = self.limit
 39
 40        field_dict: Dict[str, Any] = {}
 41        field_dict.update(self.additional_properties)
 42        field_dict.update({
 43            "pipeline_name": pipeline_name,
 44        })
 45        if workspace_id is not UNSET:
 46            field_dict["workspace_id"] = workspace_id
 47        if start is not UNSET:
 48            field_dict["start"] = start
 49        if end is not UNSET:
 50            field_dict["end"] = end
 51        if model_name is not UNSET:
 52            field_dict["model_name"] = model_name
 53        if limit is not UNSET:
 54            field_dict["limit"] = limit
 55
 56        return field_dict
 57
 58
 59
 60    @classmethod
 61    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
 62        d = src_dict.copy()
 63        pipeline_name = d.pop("pipeline_name")
 64
 65        workspace_id = d.pop("workspace_id", UNSET)
 66
 67        start = d.pop("start", UNSET)
 68
 69        end = d.pop("end", UNSET)
 70
 71        model_name = d.pop("model_name", UNSET)
 72
 73        limit = d.pop("limit", UNSET)
 74
 75        assays_get_baseline_json_body = cls(
 76            pipeline_name=pipeline_name,
 77            workspace_id=workspace_id,
 78            start=start,
 79            end=end,
 80            model_name=model_name,
 81            limit=limit,
 82        )
 83
 84        assays_get_baseline_json_body.additional_properties = d
 85        return assays_get_baseline_json_body
 86
 87    @property
 88    def additional_keys(self) -> List[str]:
 89        return list(self.additional_properties.keys())
 90
 91    def __getitem__(self, key: str) -> Any:
 92        return self.additional_properties[key]
 93
 94    def __setitem__(self, key: str, value: Any) -> None:
 95        self.additional_properties[key] = value
 96
 97    def __delitem__(self, key: str) -> None:
 98        del self.additional_properties[key]
 99
100    def __contains__(self, key: str) -> bool:
101        return key in self.additional_properties

Request to retrieve an assay baseline.

Attributes: pipeline_name (str): Pipeline name. workspace_id (Union[Unset, None, int]): Workspace identifier. start (Union[Unset, None, str]): Start date and time. end (Union[Unset, None, str]): End date and time. model_name (Union[Unset, None, str]): Model name. limit (Union[Unset, None, int]): Maximum number of baselines to return.

AssaysGetBaselineJsonBody( pipeline_name: str, workspace_id: Union[wallaroo.wallaroo_ml_ops_api_client.types.Unset, NoneType, int] = <wallaroo.wallaroo_ml_ops_api_client.types.Unset object>, start: Union[wallaroo.wallaroo_ml_ops_api_client.types.Unset, NoneType, str] = <wallaroo.wallaroo_ml_ops_api_client.types.Unset object>, end: Union[wallaroo.wallaroo_ml_ops_api_client.types.Unset, NoneType, str] = <wallaroo.wallaroo_ml_ops_api_client.types.Unset object>, model_name: Union[wallaroo.wallaroo_ml_ops_api_client.types.Unset, NoneType, str] = <wallaroo.wallaroo_ml_ops_api_client.types.Unset object>, limit: Union[wallaroo.wallaroo_ml_ops_api_client.types.Unset, NoneType, int] = <wallaroo.wallaroo_ml_ops_api_client.types.Unset object>)
2def __init__(self, pipeline_name, workspace_id=attr_dict['workspace_id'].default, start=attr_dict['start'].default, end=attr_dict['end'].default, model_name=attr_dict['model_name'].default, limit=attr_dict['limit'].default):
3    self.pipeline_name = pipeline_name
4    self.workspace_id = workspace_id
5    self.start = start
6    self.end = end
7    self.model_name = model_name
8    self.limit = limit
9    self.additional_properties = __attr_factory_additional_properties()

Method generated by attrs for class AssaysGetBaselineJsonBody.

def to_dict(self) -> Dict[str, Any]:
32    def to_dict(self) -> Dict[str, Any]:
33        pipeline_name = self.pipeline_name
34        workspace_id = self.workspace_id
35        start = self.start
36        end = self.end
37        model_name = self.model_name
38        limit = self.limit
39
40        field_dict: Dict[str, Any] = {}
41        field_dict.update(self.additional_properties)
42        field_dict.update({
43            "pipeline_name": pipeline_name,
44        })
45        if workspace_id is not UNSET:
46            field_dict["workspace_id"] = workspace_id
47        if start is not UNSET:
48            field_dict["start"] = start
49        if end is not UNSET:
50            field_dict["end"] = end
51        if model_name is not UNSET:
52            field_dict["model_name"] = model_name
53        if limit is not UNSET:
54            field_dict["limit"] = limit
55
56        return field_dict
@classmethod
def from_dict(cls: Type[~T], src_dict: Dict[str, Any]) -> ~T:
60    @classmethod
61    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
62        d = src_dict.copy()
63        pipeline_name = d.pop("pipeline_name")
64
65        workspace_id = d.pop("workspace_id", UNSET)
66
67        start = d.pop("start", UNSET)
68
69        end = d.pop("end", UNSET)
70
71        model_name = d.pop("model_name", UNSET)
72
73        limit = d.pop("limit", UNSET)
74
75        assays_get_baseline_json_body = cls(
76            pipeline_name=pipeline_name,
77            workspace_id=workspace_id,
78            start=start,
79            end=end,
80            model_name=model_name,
81            limit=limit,
82        )
83
84        assays_get_baseline_json_body.additional_properties = d
85        return assays_get_baseline_json_body
additional_keys: List[str]