Skip to main content

arg_schemas

Schemas which correspond to sets of args/kwargs for other classes.

This is most important for classes where they cannot be directly represented as schemas (for instance if they are not dataclasses themselves and so we cannot use desert) OR where we wish to have a tighter allowed range in the YAML configs than is actually allowed by the class init() method.

In particular, many of these classes are designed to avoid a bare dict as the only typing within the schemas for a "kwargs" entry.

Classes

CSVSourceArgs

class CSVSourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,    path: pathlib.Path,    read_csv_kwargs: Optional[dict[str, typing.Any]] = None,):

Args dataclass for the CSVSource's args.

Variables

  • static read_csv_kwargs : Optional[dict[str, typing.Any]]

DICOMOphthalmologySourceArgs

class DICOMOphthalmologySourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,    path: pathlib.Path,    output_path: Optional[pathlib.Path] = None,    fast_load: bool = True,    cache_images: bool = False,    infer_class_labels_from_filepaths: bool = False,    ophthalmology_args: Optional[OphthalmologyDataSourceArgs] = None,    images_only: bool = True,    dicom_ophthalmology_csv_columns: Optional[DICOMOphthalmologyCSVColumns] = None,):

Args dataclass for the DICOMOphthalmologySource's args.

Variables

DICOMSourceArgs

class DICOMSourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,    path: pathlib.Path,    output_path: Optional[pathlib.Path] = None,    fast_load: bool = True,    cache_images: bool = False,    infer_class_labels_from_filepaths: bool = False,    images_only: bool = True,):

Args dataclass for the DICOMSource's args.

Variables

  • static images_only : bool

HeidelbergSourceArgs

class HeidelbergSourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,    path: pathlib.Path,    output_path: Optional[pathlib.Path] = None,    fast_load: bool = True,    cache_images: bool = False,    infer_class_labels_from_filepaths: bool = False,    ophthalmology_args: Optional[OphthalmologyDataSourceArgs] = None,    heidelberg_csv_columns: Optional[HeidelbergCSVColumns] = None,):

Args dataclass for the HeidelbergSource's args.

Variables

ImageSourceArgs

class ImageSourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,    path: pathlib.Path,    output_path: Optional[pathlib.Path] = None,    fast_load: bool = True,    cache_images: bool = False,    infer_class_labels_from_filepaths: bool = False,    file_extensions: list[str] = None,):

Args dataclass for the ImageSource's args.

Variables

  • static file_extensions : list[str]

InterMineSourceArgs

class InterMineSourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,    service_url: str,    template_name: str,    token: Optional[str] = None,):

Args dataclass for the InterMineSource's args.

Variables

  • static service_url : str
  • static template_name : str
  • static token : Optional[str]

NullSourceArgs

class NullSourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,):

Args dataclass for the NullSource's args.

OMOPSourceArgs

class OMOPSourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,    connection_string: str,    version: str,    read_sql_kwargs: Optional[dict[str, typing.Any]] = None,):

Args dataclass for the OMOPSource's args.

Variables

  • static connection_string : str
  • static read_sql_kwargs : Optional[dict[str, typing.Any]]
  • static version : str

TopconSourceArgs

class TopconSourceArgs(    *,    seed: Optional[int] = None,    ignore_cols: Union[str, Sequence[str], ForwardRef(None)] = None,    iterable: bool = True,    partition_size: int = 16,    required_fields: Optional[dict[str, typing.Any]] = None,    path: pathlib.Path,    output_path: Optional[pathlib.Path] = None,    fast_load: bool = True,    cache_images: bool = False,    infer_class_labels_from_filepaths: bool = False,    ophthalmology_args: Optional[OphthalmologyDataSourceArgs] = None,):

Args dataclass for the TopconSource's args.