field_factory module
Define a factory to easily create the Field objects.
Todo
Implement SuperposedFieldMap.
- class FieldFactory(default_field_map_folder, load_cython_field_maps=False)[source]
Bases:
objectCreate the
Fieldand load the field maps.- _gather_primary_files_to_load(field_maps)[source]
Associate
FieldMapobjects using the same fields.SuperposedFieldMapare replaced by the list ofFieldMapthey superpose.- Parameters:
field_maps (
Collection[FieldMap|SuperposedFieldMap]) – All theFieldMapinstances requiring aField.- Return type:
- Returns:
A dictionary where each key is the tuple of arguments to instantiate a
Field, and value is the list ofFieldMapthat will share this object.
- _check_uniformity_of_types(to_load)[source]
Check that for a file name, all corresp.
object have same geom.
- run_all(field_maps)[source]
Generate the
Fieldobjects and store it in field maps.- Parameters:
field_maps (
Collection[FieldMap])- Return type:
- _create_superposed(field_maps)[source]
Create
SuperposedFieldMapfromFieldMap.Classic
FieldMapremain untouched.- Parameters:
field_maps (
Collection[FieldMap])- Return type: