- class openpnm.geometry.Imported(*args, **kwargs)¶
This geometry class extracts all numerical properites from the received network object and moves them to itself.
This class is intended for use with networks imported from network extraction codes, where the geometry properties are included on the network itself.
exclude (list of strings) – A list of which network properties should not be transferred to new geometry object. ‘pore.coords’ and ‘throat.conns’ are always excluded. Note that labels are not transferred, only properties.
pores (array_like) – The list of pores where this geometry applies.
throats (array_like) – The list of throats where this Geometry applies.
name (str) – A unique name to apply to the object. This name will also be used as a label to identify where this Geometry applies.
An error occurs when adding other geometries to a network that has geometrical properties such as ‘pore.diameter’. This can occur when adding boundary pores or in more elaborate scenarios such as stitching networks together. The issue arises because OpenPNM prevents a property, such as ‘pore.volume’, from existing on both the network and also a geometry. Thus it is necessary to move the extracted network properties to this
Importedclass, then create new geometry objects for any added pores as needed.
A shortcut to query the total number of pores on the object
A shortcut to query the total number of throats on the object
A shortcut to get a list of all pores on the object
A shortcut to get a list of all throats on the object
List of available models on the objects
String representing the name of the object
A shortcut to get a handle to the associated network.
A shortcut to get a handle to the associated physics.
A shortcut to get a handle to the associated project.
Dictionary containing object settings.
add_model(propname, model[, regen_mode])
Adds a new model to the models dictionary.
filter_by_label([pores, throats, labels, mode])
Returns which of the supplied pores (or throats) has the specified label(s)
get_conduit_data(poreprop[, throatprop, mode])
Combines requested data into a single 3-column array.
Retrieves requested property from associated objects, to produce a full Np or Nt length array.
Determines a pore (or throat) property as the average of it's neighboring throats (or pores)
labels([pores, throats, element, mode])
Returns a list of labels present on the object
Returns the number of pores of the specified labels
Return the number of throats of the specified labels
Return parameter names and values in a dictionary
pores([labels, mode, asmask, to_global])
Returns pore indicies where given labels exist, according to the logic specified by the
props([element, mode, deep])
Returns a list containing the names of all defined pore or throat properties.
regenerate_models([propnames, exclude, deep])
Re-runs the specified model or models.
Removes model and data from object.
set_label(label[, pores, throats, mode])
Creates or updates a label array
set_locations([pores, throats, mode])
Assign a Subdomain object to specific pores and/or throats
show_hist([props, bins, fontsize])
Shows a quick plot of key property distributions.
throats([labels, mode, asmask, to_global])
Returns throat locations where given labels exist, according to the logic specified by the
Convert local indices from a subdomain object to global values
Converts a boolean mask to a list of pore or throat indices.
to_local([pores, throats, missing_vals])
Convert global indices to local values relative to a subdomain object
Convert a list of pore or throat indices into a boolean mask of the correct length.