PlasmaCalcs.quantities.collisions.cross_section_tools.CrossMapping
- class PlasmaCalcs.quantities.collisions.cross_section_tools.CrossMapping(mapping={}, *, smart=True)
Bases:
SymmetricPairMappingSymmetricPairMapping where values are CrossTable objects.- smart: True, False, ‘files’, or ‘defaults’
- if smart, values can also be strings.‘files’ –> strings are interepreted as filenames.‘defaults’ –> strings are interpreted as one of the keys for CrossTable.from_defaults.True –> use ‘files’ mode if the file exists, else ‘defaults’ mode, for strings.False –> strings are not allowed; all entries must be CrossTable objects.string values are converted into CrossTable objects immediately, during self[key] = value;
- __init__(mapping={}, *, smart=True)
Methods
__init__([mapping, smart])clear()copy()items()keys()pop(key, default)update(other)values()- clear()
- remove all known items from self.
- copy()
- return a shallow copy of self.
- cross_table_type
alias of
CrossTable
- pop(key, default)
- remove self[key], and return its value. if key not in self, return default.
- update(other)
- update self with other.
other: dict of {(obj1, obj2): value}