wallaroo.wallaroo_ml_ops_api_client.models.assays_list_response_200_item_window API documentation

# wallaroo.wallaroo_ml_ops_api_client.models.assays_list_response_200_item_window

View Source

      1import datetime
      2from typing import Any, Dict, List, Type, TypeVar, Union
      3
      4import attr
      5from dateutil.parser import isoparse
      6
      7from ..types import UNSET, Unset
      8
      9T = TypeVar("T", bound="AssaysListResponse200ItemWindow")
     10
     11@attr.s(auto_attribs=True)
     12class AssaysListResponse200ItemWindow:
     13    """ Options describing the time range tested by the assay
     14
     15    Attributes:
     16        pipeline (str):  Pipeline name.
     17        model (str):  Model name.
     18        width (str):  Window width.
     19        start (Union[Unset, None, datetime.datetime]):  Window start definition.
     20        interval (Union[Unset, None, str]):  Window interval.
     21    """
     22
     23    pipeline: str
     24    model: str
     25    width: str
     26    start: Union[Unset, None, datetime.datetime] = UNSET
     27    interval: Union[Unset, None, str] = 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 = self.pipeline
     33        model = self.model
     34        width = self.width
     35        start: Union[Unset, None, str] = UNSET
     36        if not isinstance(self.start, Unset):
     37            start = self.start.isoformat() if self.start else None
     38
     39        interval = self.interval
     40
     41        field_dict: Dict[str, Any] = {}
     42        field_dict.update(self.additional_properties)
     43        field_dict.update({
     44            "pipeline": pipeline,
     45            "model": model,
     46            "width": width,
     47        })
     48        if start is not UNSET:
     49            field_dict["start"] = start
     50        if interval is not UNSET:
     51            field_dict["interval"] = interval
     52
     53        return field_dict
     54
     55
     56
     57    @classmethod
     58    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
     59        d = src_dict.copy()
     60        pipeline = d.pop("pipeline")
     61
     62        model = d.pop("model")
     63
     64        width = d.pop("width")
     65
     66        _start = d.pop("start", UNSET)
     67        start: Union[Unset, None, datetime.datetime]
     68        if _start is None:
     69            start = None
     70        elif isinstance(_start,  Unset):
     71            start = UNSET
     72        else:
     73            start = isoparse(_start)
     74
     75
     76
     77
     78        interval = d.pop("interval", UNSET)
     79
     80        assays_list_response_200_item_window = cls(
     81            pipeline=pipeline,
     82            model=model,
     83            width=width,
     84            start=start,
     85            interval=interval,
     86        )
     87
     88        assays_list_response_200_item_window.additional_properties = d
     89        return assays_list_response_200_item_window
     90
     91    @property
     92    def additional_keys(self) -> List[str]:
     93        return list(self.additional_properties.keys())
     94
     95    def __getitem__(self, key: str) -> Any:
     96        return self.additional_properties[key]
     97
     98    def __setitem__(self, key: str, value: Any) -> None:
     99        self.additional_properties[key] = value
    100
    101    def __delitem__(self, key: str) -> None:
    102        del self.additional_properties[key]
    103
    104    def __contains__(self, key: str) -> bool:
    105        return key in self.additional_properties

@attr.s(auto_attribs=True)
class AssaysListResponse200ItemWindow: View Source

     12@attr.s(auto_attribs=True)
     13class AssaysListResponse200ItemWindow:
     14    """ Options describing the time range tested by the assay
     15
     16    Attributes:
     17        pipeline (str):  Pipeline name.
     18        model (str):  Model name.
     19        width (str):  Window width.
     20        start (Union[Unset, None, datetime.datetime]):  Window start definition.
     21        interval (Union[Unset, None, str]):  Window interval.
     22    """
     23
     24    pipeline: str
     25    model: str
     26    width: str
     27    start: Union[Unset, None, datetime.datetime] = UNSET
     28    interval: Union[Unset, None, str] = 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 = self.pipeline
     34        model = self.model
     35        width = self.width
     36        start: Union[Unset, None, str] = UNSET
     37        if not isinstance(self.start, Unset):
     38            start = self.start.isoformat() if self.start else None
     39
     40        interval = self.interval
     41
     42        field_dict: Dict[str, Any] = {}
     43        field_dict.update(self.additional_properties)
     44        field_dict.update({
     45            "pipeline": pipeline,
     46            "model": model,
     47            "width": width,
     48        })
     49        if start is not UNSET:
     50            field_dict["start"] = start
     51        if interval is not UNSET:
     52            field_dict["interval"] = interval
     53
     54        return field_dict
     55
     56
     57
     58    @classmethod
     59    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
     60        d = src_dict.copy()
     61        pipeline = d.pop("pipeline")
     62
     63        model = d.pop("model")
     64
     65        width = d.pop("width")
     66
     67        _start = d.pop("start", UNSET)
     68        start: Union[Unset, None, datetime.datetime]
     69        if _start is None:
     70            start = None
     71        elif isinstance(_start,  Unset):
     72            start = UNSET
     73        else:
     74            start = isoparse(_start)
     75
     76
     77
     78
     79        interval = d.pop("interval", UNSET)
     80
     81        assays_list_response_200_item_window = cls(
     82            pipeline=pipeline,
     83            model=model,
     84            width=width,
     85            start=start,
     86            interval=interval,
     87        )
     88
     89        assays_list_response_200_item_window.additional_properties = d
     90        return assays_list_response_200_item_window
     91
     92    @property
     93    def additional_keys(self) -> List[str]:
     94        return list(self.additional_properties.keys())
     95
     96    def __getitem__(self, key: str) -> Any:
     97        return self.additional_properties[key]
     98
     99    def __setitem__(self, key: str, value: Any) -> None:
    100        self.additional_properties[key] = value
    101
    102    def __delitem__(self, key: str) -> None:
    103        del self.additional_properties[key]
    104
    105    def __contains__(self, key: str) -> bool:
    106        return key in self.additional_properties

Options describing the time range tested by the assay

Attributes: pipeline (str): Pipeline name. model (str): Model name. width (str): Window width. start (Union[Unset, None, datetime.datetime]): Window start definition. interval (Union[Unset, None, str]): Window interval.

AssaysListResponse200ItemWindow( pipeline: str, model: str, width: str, start: Union[wallaroo.wallaroo_ml_ops_api_client.types.Unset, NoneType, datetime.datetime] = <wallaroo.wallaroo_ml_ops_api_client.types.Unset object>, interval: Union[wallaroo.wallaroo_ml_ops_api_client.types.Unset, NoneType, str] = <wallaroo.wallaroo_ml_ops_api_client.types.Unset object>) View Source

    2def __init__(self, pipeline, model, width, start=attr_dict['start'].default, interval=attr_dict['interval'].default):
    3    self.pipeline = pipeline
    4    self.model = model
    5    self.width = width
    6    self.start = start
    7    self.interval = interval
    8    self.additional_properties = __attr_factory_additional_properties()

Method generated by attrs for class AssaysListResponse200ItemWindow.

def to_dict(self) -> Dict[str, Any]: View Source

    32    def to_dict(self) -> Dict[str, Any]:
    33        pipeline = self.pipeline
    34        model = self.model
    35        width = self.width
    36        start: Union[Unset, None, str] = UNSET
    37        if not isinstance(self.start, Unset):
    38            start = self.start.isoformat() if self.start else None
    39
    40        interval = self.interval
    41
    42        field_dict: Dict[str, Any] = {}
    43        field_dict.update(self.additional_properties)
    44        field_dict.update({
    45            "pipeline": pipeline,
    46            "model": model,
    47            "width": width,
    48        })
    49        if start is not UNSET:
    50            field_dict["start"] = start
    51        if interval is not UNSET:
    52            field_dict["interval"] = interval
    53
    54        return field_dict

@classmethod
def from_dict(cls: Type[~T], src_dict: Dict[str, Any]) -> ~T: View Source

    58    @classmethod
    59    def from_dict(cls: Type[T], src_dict: Dict[str, Any]) -> T:
    60        d = src_dict.copy()
    61        pipeline = d.pop("pipeline")
    62
    63        model = d.pop("model")
    64
    65        width = d.pop("width")
    66
    67        _start = d.pop("start", UNSET)
    68        start: Union[Unset, None, datetime.datetime]
    69        if _start is None:
    70            start = None
    71        elif isinstance(_start,  Unset):
    72            start = UNSET
    73        else:
    74            start = isoparse(_start)
    75
    76
    77
    78
    79        interval = d.pop("interval", UNSET)
    80
    81        assays_list_response_200_item_window = cls(
    82            pipeline=pipeline,
    83            model=model,
    84            width=width,
    85            start=start,
    86            interval=interval,
    87        )
    88
    89        assays_list_response_200_item_window.additional_properties = d
    90        return assays_list_response_200_item_window

additional_keys: List[str]