RUFAS.routines.animal.animal_grouping_scenarios module#
- class RUFAS.routines.animal.animal_grouping_scenarios.AnimalGroupingScenario(*values)#
Bases:
Enum
The different scenarios for grouping animals on a farm. Each scenario is a dictionary of the form: { AnimalCombination: [List of animal types/subtypes] }
- CALF__GROWING__CLOSE_UP__LACCOW = {AnimalCombination.CALF: [AnimalType.CALF], AnimalCombination.CLOSE_UP: [AnimalType.HEIFER_III, AnimalType.DRY_COW], AnimalCombination.GROWING: [AnimalType.HEIFER_I, AnimalType.HEIFER_II], AnimalCombination.LAC_COW: [AnimalType.LAC_COW]}#
- CALF__GROWING_AND_CLOSE_UP__LACCOW = {AnimalCombination.CALF: [AnimalType.CALF], AnimalCombination.GROWING_AND_CLOSE_UP: [AnimalType.HEIFER_I, AnimalType.HEIFER_II, AnimalType.HEIFER_III, AnimalType.DRY_COW], AnimalCombination.LAC_COW: [AnimalType.LAC_COW]}#
- __init__(value: Dict[AnimalCombination, List[str]])#
Initialize the AnimalGroupingScenario.
Parameters#
- valueDict[AnimalCombination, List[str]]
The value of the AnimalGroupingScenario.
- _get_calf_type(calf: Calf) AnimalType #
Get the animal subtype of the given calf.
Parameters#
- calfCalf
The calf to get the animal subtype of.
Returns#
- AnimalType
The animal subtype of the given calf.
- _get_heiferI_type(heiferI: HeiferI) AnimalType #
Get the animal subtype of the given heiferI.
Parameters#
- heiferIHeiferI
The heiferI to get the animal subtype of.
Returns#
- AnimalType
The animal subtype of the given heiferI.
- _get_heiferII_type(heiferII: HeiferII) AnimalType #
Get the animal subtype of the given heiferII.
Parameters#
- heiferIIHeiferII
The heiferII to get the animal subtype of.
Returns#
- AnimalType
The animal subtype of the given heiferII.
- _get_heiferIII_type(heiferIII: HeiferIII) AnimalType #
Get the animal subtype of the given heiferIII.
Parameters#
- heiferIIIHeiferIII
The heiferIII to get the animal subtype of.
Returns#
- AnimalType
The animal subtype of the given heiferIII.
- _get_cow_type(cow: Cow) AnimalType #
Get the animal subtype of the given cow.
Parameters#
- cowCow
The cow to get the animal subtype of.
Returns#
- AnimalType
The animal subtype of the given cow.
- get_animal_type(animal: Calf | HeiferI | HeiferII | HeiferIII | Cow) AnimalType #
Get the animal type of the given animal.
Parameters#
- animalUnion[Calf, HeiferI, HeiferII, HeiferIII, Cow]
The animal to get the animal type of.
Returns#
- AnimalType
The animal type of the given animal.
- find_animal_combination(animal: Calf | HeiferI | HeiferII | HeiferIII | Cow) AnimalCombination #
Find the animal combination that the given animal belongs to.
Parameters#
- animalUnion[Calf, HeiferI, HeiferII, HeiferIII, Cow]
The animal to find the animal combination for.
Returns#
- AnimalCombination
The animal combination that the given animal belongs to.