czbenchmarks.datasets.types

Attributes

DataValue

Classes

Organism

Create a collection of name/value pairs.

DataTypeSpec

Specification for a data type in the system

DataType

Create a collection of name/value pairs.

Module Contents

class czbenchmarks.datasets.types.Organism(name: str, prefix: str)[source]

Bases: enum.Enum

Create a collection of name/value pairs.

Example enumeration:

>>> class Color(Enum):
...     RED = 1
...     BLUE = 2
...     GREEN = 3

Access them by:

  • attribute access:

>>> Color.RED
<Color.RED: 1>
  • value lookup:

>>> Color(1)
<Color.RED: 1>
  • name lookup:

>>> Color['RED']
<Color.RED: 1>

Enumerations can be iterated over, and know how many members they have:

>>> len(Color)
3
>>> list(Color)
[<Color.RED: 1>, <Color.BLUE: 2>, <Color.GREEN: 3>]

Methods can be added to enumerations, and members can have their own attributes – see the documentation for details.

HUMAN = ('homo_sapiens', 'ENSG')
MOUSE = ('mus_musculus', 'ENSMUSG')
TROPICAL_CLAWED_FROG = ('xenopus_tropicalis', 'ENSXETG')
AFRICAN_CLAWED_FROG = ('xenopus_laevis', 'ENSXLAG')
ZEBRAFISH = ('danio_rerio', 'ENSDARG')
MOUSE_LEMUR = ('microcebus_murinus', 'ENSMICG')
WILD_BOAR = ('sus_scrofa', 'ENSSSCG')
CRAB_EATING_MACAQUE = ('macaca_fascicularis', 'ENSMFAG')
RHESUS_MACAQUE = ('macaca_mulatta', 'ENSMMUG')
PLATYPUS = ('ornithorhynchus_anatinus', 'ENSOANG')
OPOSSUM = ('monodelphis_domestica', 'ENSMODG')
GORILLA = ('gorilla_gorilla', 'ENSGGOG')
CHIMPANZEE = ('pan_troglodytes', 'ENSPTRG')
MARMOSET = ('callithrix_jacchus', 'ENSCJAG')
CHICKEN = ('gallus_gallus', 'ENSGALG')
RABBIT = ('oryctolagus_cuniculus', 'ENSOCUG')
FRUIT_FLY = ('drosophila_melanogaster', 'FBgn')
RAT = ('rattus_norvegicus', 'ENSRNOG')
NAKED_MOLE_RAT = ('heterocephalus_glaber', 'ENSHGLG')
CAENORHABDITIS_ELEGANS = ('caenorhabditis_elegans', 'WBGene')
YEAST = ('saccharomyces_cerevisiae', '')
MALARIA_PARASITE = ('plasmodium_falciparum', 'PF3D7')
SEA_LAMPREY = ('petromyzon_marinus', 'ENSPMAG')
FRESHWATER_SPONGE = ('spongilla_lacustris', 'ENSLPGG')
CORAL = ('stylophora_pistillata', 'LOC')
SEA_URCHIN = ('lytechinus_variegatus', '')
__str__()[source]
__repr__()[source]
property name

The name of the Enum member.

property prefix
class czbenchmarks.datasets.types.DataTypeSpec[source]

Specification for a data type in the system

name: str
dtype: Type
description: str
is_input: bool = True
class czbenchmarks.datasets.types.DataType(*args, **kwds)[source]

Bases: enum.Enum

Create a collection of name/value pairs.

Example enumeration:

>>> class Color(Enum):
...     RED = 1
...     BLUE = 2
...     GREEN = 3

Access them by:

  • attribute access:

>>> Color.RED
<Color.RED: 1>
  • value lookup:

>>> Color(1)
<Color.RED: 1>
  • name lookup:

>>> Color['RED']
<Color.RED: 1>

Enumerations can be iterated over, and know how many members they have:

>>> len(Color)
3
>>> list(Color)
[<Color.RED: 1>, <Color.BLUE: 2>, <Color.GREEN: 3>]

Methods can be added to enumerations, and members can have their own attributes – see the documentation for details.

METADATA
ANNDATA
ORGANISM
EMBEDDING
CONDITION_KEY
SPLIT_KEY
PERTURBATION_PRED
PERTURBATION_TRUTH
property spec: DataTypeSpec
property dtype: Type
property description: str
property is_input: bool
property is_output: bool
__hash__()[source]
__eq__(other)[source]
__str__()[source]
__repr__()[source]
czbenchmarks.datasets.types.DataValue