bw2parameters.pint#

Attributes#

Classes#

Module Contents#

class bw2parameters.pint.PintWrapperSingleton[source]#
get_dimensionality(unit_name=None)[source]#
is_quantity(value)[source]#
is_quantity_from_same_registry(value)[source]#
to_quantity(amount, unit=None)[source]#

Return a pint.Quantity if a unit is given, otherwise the amount.

to_unit(string, raise_errors=False)[source]#

Returns pint.Unit if the given string can be interpreted as a unit, returns None otherwise

to_units(iterable, raise_errors=False, drop_none=True)[source]#

Takes and iterable and tries to interpret each element as a pint.Unit. Returns a dict where key is the original element and value is the interpreted pint.Unit. Elements which cannot be interpreted as a pint.Unit are None (or dropped if drop_none == True).

bw2parameters.pint.PintWrapper[source]#