stubs.common¶
General functions: array manipulation, data i/o, etc
Functions
|
|
|
|
|
|
|
pandas requires some weird manipulation to insert some things, e.g. |
|
Interpolates t and y such that dy between time points is never greater than max_dy Maintains all original t and y |
|
Converts a json_str (either a string of the json itself, or a filepath to the json) |
|
|
|
|
|
Quality of life function. |
|
|
|
Rounds to n sig figs |
|
Takes dof indices (single index or a list) on a submesh of a boundarymesh of a mesh and returns the dof indices of the original mesh. |
|
|
|
|
|
ty1: Numpy array of size N1 x 2 where the first column is time and the second column is the first signal ty2: Numpy array of size N2 x 2 where the first column is time and the second column is the second signal |
|
Takes a ParameterDF, SpeciesDF, CompartmentDF, and ReactionDF, and generates a .smodel file (a convenient concatenation of .json files with syntax similar to .xml) |
Classes
|
Pandas dataframe doesn't play nice with dolfin indexed functions since it will try to take the length but dolfin will not return anything. |