mx_verify module
Step to allow global fitting of multiple measurements ti simulation data. Step is based upon XVerify (see x_verify.py)
Author: Pascal Kuthe | PascalKuthe@pm.me
- class DMT.extraction.mx_verify.MXVerify(name, mcard, lib, op_definition, DutCircuitClass, relevant_duts=None, model_deemb_method=None, verify_area_densities=False, **kwargs)[source]
Bases:
XStep
- add_to_xtraction(xtraction)[source]
Sets the duts from xtraction to the given step
- Parameters:
- xtraction
XTraction
]
- xtraction
- calc_all(*args, **kwargs)[source]
This method needs to start the calculation of the function to be optimized self.f_0 and its jacobian self.jac .
Calculating the jacobian here allows to use DMT’s parallel computing features, which might be relevant for circuit or TCAD simulations.
This function is called inside fit_function.
- Parameters:
- xdata
np.ndarray
The argument of the fit_function, scipy.curve_fit wants to calculate.
- paras_model
McParameterCollection
Parameters of the model to calculate. Can bei either a full modelcard or only a McParameterCollection.
- jac{
True
,False
},optional
This boolean controls wheather or not the jacobian is computed.
- reinit
Boolean
What is this?
- n_optimize
integer
The number of parameters to optimize. Not really needed but for memoization in XVerify.
- xdata
- Returns:
- self.data_model
dict
{} This is only returned in order to enable memoization. It is actually not really needed for anything else.
- self.data_model
- fit(line, paras_model, dut=None)[source]
Implementation is similar to the one in XVerify However in this implementation the data for each quantity is concatenated to form the full data Furthermore the data is normalized for each quantity individually and the bounds of each subset are applied to the line
- fit_along: List[SpecifierStr][source]
- get_bool_array(line_ref, bounds=None)[source]
Return a boolean array, where True means that the value in line_ref is inside the bounds.
- Parameters:
- line_ref{}
A dictionarray of a line that has at least the keys “x” and “y”
- bounds
DMT.extraction.XBounds
,YBounds
orXYBounds
The boundaries that shall be used to determine which values in bool_array are true
- Returns
np.array
() An array that has “True” where the value in “x” or “y”, depending on the type of bounds, is inside the bounds.
- get_description()[source]
Return a tex description of this XStep. Used for generating the documentation. If not implemented, there is no description for this XStep in the documentation.
- get_tex()[source]
Return a tex Representation of the Model that is beeing fitted. This can then be displayed in the UI.
- init_data_reference()[source]
Find the required data in the user supplied dataframe or database and write them into data_model attribute of XStep object.
- quantity_fit: List[SpecifierStr][source]
- set_initial_guess(data_reference)[source]
This methods should set an initial guess for the optimization parameters from the available reference_data array. If no initial guess is set for a parameter, the value for the initial guess is taken form the modelcard. For steps which use a simulation of a DutCircuit, here the sweep should be defined, too.
- sort_line(line)[source]
Sort all values in line with increasing “x” or “y” or self.sort_by and cast everything to numpy.
- Returns:
line
:{str:[]}The sorted line.
- y_normalizers: List[IYNorm][source]
Step class inherits always from XStep.
- Parameters:
- name
str
Name of this specific xcjei object.
- mcard
MCard
orMcParameterCollection
This MCard needs to hold all relevant parameters of the model and is used for simulations or model equation calculations.
- lib
DutLib
This library of devices needs to hold a relevant reference dut with data in one or more DataFrames.
- op_definition{
key
float
,tuple
orlist
}
- name