libvna.cal Module

This module uses measurements of calibration standards to find error terms for vector network analyzers (VNAs). It applies the resulting calibration to measurements of devices under test to correct for the errors.

The basic sequence for generating a new calibration is:

  1. Create a Calset object, then use calset.solver() to make a Solver object.

  2. Make measurements of calibration standards and add them using the Solver.add_* methods.

  3. Solve using Solver.solve()

  4. Use Solver.add_to_calset() to add the new calibration to the Calset

  5. Use Calset.save() to save the calibration to a file

The sequence for applying a calibration to a device measurement is:

  1. Load the calibration by passing the saved calibration filename to the Calset constructor.

  2. Get the Calibration object from the Calset.calibrations attribute.

  3. Measure the device under test.

  4. Use Calibration.apply() to apply the calibration correction to the measurements.

Calset

class libvna.cal.Calset(filename=None) Calset

The Calset is a container of solved calibrations and a context for creating new calibrations.

Though the Calset usually holds just one calibration, it can hold any number of calibrations, for example, covering different frequency bands or test set configurations.

Parameters:

filename (str, optional) – Load the Calset from the given file. Note that the suggested extension of .vnacal is not added automatically.

Quick Reference - Calset methods by category:

Calset.calibrations

Vector of solved Calibration objects in this Calset. Behaves like an ordered dictionary where calibrations can be indexed by int, or a str containing the name of the calibration. Supports iteration, index, contains and del.

Calibration Objects

class libvna.cal.Calibration

A solved calibration. Note: you cannot instantiate this class directly: use Calset.calibrations to access instances of this class.

name

Name of the calibration (str, readonly)

ctype

Type of the calibration (CalType, readonly)

rows

number of rows in the calibration (int, readonly)

columns

number of columns in the calibration (int, readonly)

frequencies

number of frequencies in the calibration (int, readonly)

frequency_vector

vector of calibration frequencies (array of float, readonly)

z0

reference impedance of all ports in the calibration (complex, readonly)

properties

Tree of nested dictionaries, lists, scalars and None values representing arbitrary user-defined metadata to be saved with the calibration. Examples might include calibration date, cable lengths, and test set used.

apply(f, b, *, a=None, delay_vector=None) NPData

Apply the calibration correction to measured data. The calibration must have dimensions 2x1, 1x2, or NxN.

Parameters:
  • f (array of float or None) – vector of frequencies at which the measurements were made, or None if measured at the calibration frequencies

  • b (sequence of complex matrices) – Raw VNA measurements at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes received on the measured ports at that excitation.

  • a (sequence of complex matrices, optional) – When present, measurements of the signals leaving the VNA ports at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes leaving the measured ports at that excitation. Note that use of an a matrix here must match use of the a matrix during calibration.

  • delay_vector (list/array of float, optional) – Deprecated. Delay in seconds between the reference plane and each port of the DUT. Delays can be negative.

Returns:

NPData object containing the corrected parameters

Calibration Standards

The following methods create calibration kit and data-based standards that can be used with the Solver class below.

libvna.cal.Calset.short_standard(offset_delay: float = 0.0, offset_loss: float = 0.0, offset_z0: float = 50.0, fmin: float = 0.0, fmax: float = INFINITY, traditional: bool = False, L: List[float] | None = None) ShortStandard
libvna.cal.Calset.open_standard(offset_delay: float = 0.0, offset_loss: float = 0.0, offset_z0: float = 50.0, fmin: float = 0.0, fmax: float = INFINITY, traditional: bool = False, C: List[float] | None = None) OpenStandard
libvna.cal.Calset.load_standard(offset_delay: float = 0.0, offset_loss: float = 0.0, offset_z0: float = 50.0, fmin: float = 0.0, fmax: float = INFINITY, traditional: bool = False, Zl: complex = 50.0) LoadStandard
libvna.cal.Calset.through_standard(offset_delay: float = 0.0, offset_loss: float = 0.0, offset_z0: float = 50.0, fmin: float = 0.0, fmax: float = INFINITY, traditional: bool = False) ThroughStandard
libvna.cal.Calset.data_standard(npdata: NPData) DataStandard

These standards have defined characteristic impedances based on the offset_z0 parameter or reference impedance given with the data standard. If used with a VNA port with a different reference impedance, they automatically re-normlize the reference impedance.

Parameters

The library also provides a lower-level way to specify standards, where each element of the S-parameter matrix of the standard is given as a Parameter object. Parameter objects include scalar type that have a constant value for all frequencies, such as -1.0 for short, 1.0 for open, and 0.0 for match, vector type given as a vector of frequency points and a vector of values, unknown type that are only approximately known such as the R and L parameters in TRL calibration, and correlated type that are known only to be statistically related to other parameters. The library solves for unknown and correlated parameters at the same time it solves for the error terms. These Parameter objects do not have a defined reference impedance and its the caller’s responsibilty to ensure that parameters are meaningful for the VNA ports on which they are used.

Calset.scalar_parameter(value) ScalarParameter

Return an element of the S-parameter matrix of a calibration standard that has a constant value at all frequencies, e.g. -1 for short.

Parameters:

value (complex) – an element of the S-parameter matrix of the standard that doesn’t depend on frequency, e.g. 0 for match

Calset.vector_parameter(frequency_vector, value_vector) VectorParameter

Return an element of the S-parameter matrix of a calibration standard that varies with frequency.

Parameters:
  • frequency_vector (vector of float) – monotonically increasing list of frequencies

  • value_vector (vector of complex) – list or array of complex values corresponding to each frequency in frequency_vector

The frequencies must cover the entire span of the calibration frequency range, but do not have to coincide with the calibration frequencies – the library uses rational function interpolation as needed to interpolate between frequency points.

Calset.unknown_parameter(initial_guess) UnknownParameter

Return an element of the S-parameter matrix of a calibration standard that is only approximately known that the library must determine.

Parameters:

initial_guess

approximate value of the unknown parameter

May be specified as a complex scalar, (frequency_vector, value_vector) tuple, or a Parameter.

Calset.correlated_parameter(other, frequency_vector, sigma_vector) CorrelatedParameter

Return an element of the S-parameter matrix of a calibration standard that is known to be correlated with another (possibly unknown) Parameter. This type of parameter is useful for modeling connection non-repeatability.

Parameters:
  • other

    another Parameter to which this Parameter is known to be correlated

    May be specified as a complex scalar, (frequency_vector, value_vector) tuple, or a Parameter.

  • frequency_vector (vector of float) – monotonically increasing list of frequencies

  • sigma_vector (vector of float) – standard deviation between this Parameter and its correlate at each frequency

The frequencies must cover at least the entire span of the calibration frequency range, but do not have to coincide with the calibration frequencies – the library uses natural cubic spline interpolation as needed to interpolate between points.

Calset.parameter(value) Parameter

Return an element of the S-parameter matrix of a calibration standard constructed from the given value.

Parameters:

value – If a scalar, return a ScalarParameter. If tuple(frequency_vector, value_vector), return a VectorParameter. If already a parameter, just return it.

Calset.parameter_matrix(array) ParameterMatrix

Return an array of Parameter objects representing the S-parameters of a calibration standard constructed from the given array.

Parameters:

array

an array-like object or an NPData object

When an array is given, the elements may be complex scalar, (frequency_vector, value_vector) tuple, or Parameter.

Standard and Parameter Classes

class libvna.cal.Parameter

An element of the S-parameter matrix describing a calibration standard. The Parameter is an abstraction that can represent a single complex scalar such as -1 for short, a tuple(frequency_vector, value_vector) representing a reflect with complex impedance or the through component of a transmission line, an unknown parameter the library will solve for, e.g. the R or L parameters in TRL, or the element of a calkit or data standard.

Note: this class cannot be instantiated directly. Use the factory methods: Calset.short_standard(), Calset.open_standard(), Calset.load_standard(), Calset.parameter(), Calset.scalar_parameter(), Calset.vector_parameter(), Calset.unknown_parameter(), and Calset.correlated_parameter().

eval(f, z0=50.0)

Return the value of the parameter at each given frequency and reference impedance with output in the same shape as frequencies.

Parameters:
  • frequencies (float or array of float) – frequencies at which to evaluate the value.

  • z0 (complex, optional) – reference impedance (defaults to 50 ohms)

For a scalar parameter, the function ignores frequency and simply returns the fixed value value. For a vector parameter, it returns the value value at the given frequency, interpolating as necessary. If the parameter is unknown and Solver.solve() has completed successfully, get_value() returns the solved value, again interpolating as necessary.

embed(fixture) Parameter

Embed the parameter in a two-port test fixture.

Parameters:

fixture (2x2 array of Parameter) – ParameterMatrix describing the test fixture. The first port faces the VNA; second port faces the DUT.

Returns:

A new Parameter, that when evaluated includes the effect of the test fixture on the DUT.

deembed(fixture) Parameter

De-embed the parameter out of a two-port test fixture.

Parameters:

fixture (2x2 array of Parameter) – ParameterMatrix describing the test fixture. The first port faces the VNA; second port faces the DUT.

Returns:

A new Parameter, that when evaluated removes the effect of the test fixture.

class libvna.cal.ParameterMatrix

Bases: ndarray

An array of Parameter objects describing the S-parameter matrix of a multi-port calibration standard.

Note: this class cannot be instantiated directly. Use the factory methods: Calset.through_standard(), Calset.data_standard(), Calset.parameter_matrix(), and Calset.parameter().

eval(f, z0=50.0)

Evaluate the standard at one or more frequencies.

Parameters:
  • f (float or array_like of float) – Frequency or list/array of frequencies at which to evaluate. If a single scalar is provided, the result is 2D (rows × columns). If multiple frequencies are provided, the result is 3D (frequencies × rows × columns).

  • z0 (complex, optional) –

    reference impedances (defaults to 50 ohms)

    Can be: a scalar (same impedance for all ports and frequencies), a 1D array of length ports (same for all frequencies), or a 2D array of shape (frequencies, ports) for per-frequency, per-port values

Returns:

ndarray of complex

If frequency_vector is scalar: shape (rows, columns). Otherwise: shape (frequencies, rows, columns).

to_npdata(frequency_vector, z0=50.0) NPData

Construct an NPData object from the standard.

Parameters:
  • frequency_vector (vector of float) – monotonically increasing list of frequencies

  • z0 (complex, optional) –

    reference impedances (defaults to 50 ohms)

    z0 can be specified as a scalar, number of ports long vector, or frequencies by ports matrix.

embed(fixture) ParameterMatrix

Embed the parameter matrix in a test fixture.

Parameters:

fixture (array of Parameter) – Square ParameterMatrix describing the test fixture. The number of rows and columns in fixture must be exactly twice those of the DUT. Indices 0..(n-1) face the VNA while indices n..(2n-1) face the DUT, where n is the number of DUT ports.

Returns:

A new ParameterMatrix, that when evaluated includes the effect of the test fixture on the DUT.

deembed(fixture) ParameterMatrix

De-embed the parameter matrix from a test fixture.

Parameters:

fixture (array of Parameter) – Square ParameterMatrix describing the test fixture. The number of rows and columns in fixture must be exactly twice those of the DUT. Indices 0..(n-1) face the VNA while indices n..(2n-1) face the DUT, where n is the number of DUT ports.

Returns:

A new ParameterMatrix, that when evaluated removes the effect of the test fixture on the DUT.

class libvna.cal.ScalarParameter(calset: Calset, value) ScalarParameter

Bases: Parameter

class libvna.cal.VectorParameter(calset: Calset, frequency_vector, value_vector) VectorParameter

Bases: Parameter

class libvna.cal.UnknownParameter(calset: Calset, initial_guess) UnknownParameter

Bases: Parameter

class libvna.cal.CorrelatedParameter(calset: Calset, other, frequency_vector, sigma_vector) CorrelatedParameter

Bases: Parameter

class libvna.cal.ShortStandard(calset: Calset, offset_delay: float = 0.0, offset_loss: float = 0.0, offset_z0: float = 50.0, fmin: float = 0.0, fmax: float = INFINITY, traditional: bool = False, L: List[float] | None = None) ShortStandard

Bases: Parameter

class libvna.cal.OpenStandard(calset, offset_delay=0.0, offset_loss=0.0, offset_z0=50.0, fmin=0.0, fmax=INFINITY, traditional=False, C=None) OpenStandard

Bases: Parameter

class libvna.cal.LoadStandard(calset, offset_delay=0.0, offset_loss=0.0, offset_z0=50.0, fmin=0.0, fmax=INFINITY, traditional=False, Zl=50.0) LoadStandard

Bases: Parameter

class libvna.cal.ThroughStandard(calset, offset_delay=0.0, offset_loss=0.0, offset_z0=50.0, fmin=0.0, fmax=INFINITY, traditional=False) ThroughStandard

Bases: ParameterMatrix

class libvna.cal.DataStandard(calset: Calset, npdata: NPData) DataStandard

Bases: ParameterMatrix

Solving a Calibration

The Solver class takes measurements of calibration standards, solves for the error terms and adds the new calibration to the Calset.

Calset.solver(ctype, rows, columns, frequency_vector, z0=50.0) Solver

Error Term Solver: solve for VNA error terms from measurements of calibration standards.

Parameters:
  • ctype (CalType) –

    The calibration type determines which error terms the library corrects. Valid values are:

    T8, U8:

    8-term T or U parameters: correct for directivity, reflection / transmission tracking, and port match errors on each VNA port. At least three standards, (e.g. short-open, short-match, through) are needed to solve the 2x2 T8 or U8 calibration.

    TE10, UE10:

    8-term T or U parameters plus 2 leakage: correct for the same errors as T8 and U8, but also correct for leakage within the VNA from the driving port to the other ports. At least three standards (e.g. short-open, short-match, through) are needed to solve the 2x2 TE10 or UE10 calibration.

    T16, U16:

    16-term T or U parameters: correct for the same errors as TE10 and UE10, but add the remaining leakage terms including leakage between the DUT ports in the test fixture. At least five standards (e.g. short-open, short-match, open-match, open-short, through) are needed to solve the 2x2 T16 or U16 calibration.

    UE14:

    Correct for the same errors as TE10 and UE10, except treat each column (driving port) as an independent calibration. This type produces separate error parameters for the forward and reverse directions, and for this reason, it’s able to correct for errors in the forward-reverse switch without reference (a matrix) measurements, even for a switch that lies between the detectors and the DUT. At least four standards (e.g. short-open, match-open, match-short, through) are needed to solve the 2x2 UE14 calibration.

    E12:

    Generalization of classic SOLT: the library uses UE14 terms internally to solve this calibration, and this type corrects for exactly the same errors at UE14. The difference is only in the representation of the saved error terms. After finding the UE14 error terms, the library converts from inverse scattering transfer (U) error terms to scattering error terms (E). At least four standards (e.g. short-open, match-open, match-short, through) are needed to solve the 2x2 E12 calibration.

  • rows (int) – number of rows in the calibration, where rows is the number of VNA ports that detect signal. Normally, rows and columns are both simply the number of VNA ports. Some simple VNAs, however, measure only a subset of the S-parameters such as \(S_{11}\) and \(S_{21}\). If the VNA measures \(S_{11}\) and \(S_{21}\) only, set rows to 2 and columns to 1. If the VNA measures \(S_{11}\) and \(S_{12}\) only, set rows to 1 and columns to 2. In general, if rows > columns, U parameters must be used; if rows < columns, T parameters must be used. For square calibrations, either T or U parameters may be used.

  • columns (int) – number columns in the calibration, where columns is the number of VNA ports that transmit signal. See rows.

  • frequency_vector (list/array of float) – vector of frequency points to be used in the calibration. Must be monotonically increasing

  • z0 (complex or array-like of complex, optional) –

    reference impedance of the VNA ports. Can be specified as:

    • A scalar complex value if all ports have the same impedance at all frequencies.

    • A 1D array of length ports (where ports is max(rows, columns)) if each port has a different but frequency-independent impedance.

    • A 2D array of shape (frequencies, ports) if the impedance varies by both port and frequency.

    If not specified, z0 defaults to 50 ohms.

Note that the calibration method used, e.g. LRL, LRM, LRRL, LRRM, LXYZ, SOLT, TRD, TRL, TRM, TXYZ, UXYZ, etc., does not have to be specified. The library automatically determines the method based on the standards given, or uses a general solver if it does not have a special solver for the given set of standards. The main requirement is that the standards used must provide a sufficient number of conditions for the number of unknowns to be solved.

class libvna.cal.Solver
add_single_reflect(b, s11, *, a=None, delay=0.0, port=1)

Add the measurement of a single reflect standard with parameter s11 on the given VNA port.

Parameters:
  • b (sequence of complex matrices) – Raw VNA measurements at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes received on the measured ports at that excitation.

  • s11

    \(S_{11}\) parameter of the calibration standard

    May be specified as complex scalar, a (frequency_vector, value_vector) tuple, a Parameter, or a 1×1 ParameterMatrix.

  • a (sequence of complex matrices, optional) – When present, measurements of the signals leaving the VNA ports at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes leaving the measured ports at that excitation.

  • delay (float, optional) – Deprecated. Delay in seconds between the reference plane and the standard. Can be negative.

  • port (int, optional) – VNA port number connected to the standard. If not given, defaults to 1.

add_double_reflect(b, s11, s22, *, a=None, delay1=0.0, delay2=0.0, port1=1, port2=2)

Add the measurement of a double reflect standard with parameters s11 and s22 on the given VNA ports, assuming \(S_{12} = S_{21} = 0\).

Parameters:
  • b (sequence of complex matrices) – Raw VNA measurements at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes received on the measured ports at that excitation.

  • s11

    \(S_{11}\) parameter of the calibration standard

    May be specified as complex scalar, a (frequency_vector, value_vector) tuple, a Parameter, or a 1×1 ParameterMatrix.

  • s22

    \(S_{22}\) parameter of the calibration standard

    May be specified as complex scalar, a (frequency_vector, value_vector) tuple, a Parameter, or a 1×1 ParameterMatrix.

  • a (sequence of complex matrices, optional) – When present, measurements of the signals leaving the VNA ports at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes leaving the measured ports at that excitation.

  • delay1 (float, optional) – Deprecated. Delay in seconds between the reference plane and port 1 of the standard. Can be negative.

  • delay2 (float, optional) – Deprecated. Delay in seconds between the reference plane and port 2 of the standard. Can be negative.

  • port1 (int, optional) – VNA port number connected to port 1 of the calibration standard. If not given, defaults to 1.

  • port2 (int, optional) – VNA port number connected to port 2 of the calibration standard. If not given, defaults to 2.

add_through(b, *, a=None, delay=0.0, port1=1, port2=2)

Add the measurement of a perfect through standard between port1 and port2, i.e. \(S_{12} = S_{21} = 1\) and \(S_{11} = S_{22} = 0\).

Parameters:
  • b (sequence of complex matrices) – Raw VNA measurements at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes received on the measured ports at that excitation.

  • a (sequence of complex matrices, optional) – When present, measurements of the signals leaving the VNA ports at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes leaving the measured ports at that excitation.

  • delay (float, optional) – Deprecated. Delay in seconds of the standard. Can be negative.

  • port1 (int, optional) – first VNA port connected to the through standard. If not given, defaults to 1.

  • port2 (int, optional) – second VNA port connected to the through standard. If not given, defaults to 2.

add_line(b, s, *, a=None, delay1=0.0, delay2=0.0, port1=1, port2=2)

Add the measurement of an arbitrary two-port standard with S parameter matrix, s, on the given VNA ports.

Parameters:
  • b (sequence of complex matrices) – Raw VNA measurements at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes received on the measured ports at that excitation.

  • s (2x2 matrix) – S-parameter matrix of the standard. Can be specified as a 2×2 ParameterMatrix, or a matrix where each element is complex scalar, a (frequency_vector, value_vector) tuple, or Parameter.

  • a (sequence of complex matrices, optional) – When present, measurements of the signals leaving the VNA ports at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes leaving the measured ports at that excitation.

  • delay1 (float, optional) – Deprecated. Delay in seconds between the reference plane and port 1 of the standard. Can be negative.

  • delay2 (float, optional) – Deprecated. Delay in seconds between the reference plane and port 2 of the standard. Can be negative.

  • port1 (int, optional) – VNA port number connected to port 1 of the calibration standard. If not given, defaults to 1.

  • port2 (int, optional) – VNA port number connected to port 2 of the calibration standard. If not given, defaults to 2.

add_mapped_matrix(b, s, *, a=None, delay_vector=None, port_map=None)

Add the measurement of an arbitrary n-port standard with S parameter matrix, s, and a map of ports of the standard to ports of the VNA in port_map.

Parameters:
  • b (sequence of complex matrices) – Raw VNA measurements at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes received on the measured ports at that excitation.

  • s (matrix) – S-parameter matrix of the standard. Can be specified as a ParameterMatrix, or a matrix where each element is complex scalar, a (frequency_vector, value_vector) tuple, or Parameter.

  • a (sequence of complex matrices, optional) – When present, measurements of the signals leaving the VNA ports at each frequency. Each entry is a complex matrix whose columns correspond to the driven ports and whose rows give the complex amplitudes leaving the measured ports at that excitation.

  • delay_vector (list/array of float, optional) – Deprecated. Vector of delays in seconds between the reference plane and each port of the standard. Delays can be negative.

  • port_map (list/array of int, optional) – list of the VNA port numbers attached to each port of the standard in order. Optional if the standard has the same number of ports as the VNA and the ports of the VNA are attached to the corresponding port numbers of the standard. VNA port numbers start with 1.

set_m_error(frequency_vector, noise_floor, tracking_error=None)

Enable measurement error modeling.

Parameters:
  • frequency_vector (vector of float) – vector of ascending frequencies spanning calibration frequency range

  • noise_floor (vector of float) – vector of noise floor root-power measurements at the VNA detectors at each frequency when no signal is applied

  • tracking_error (vector of float, optional) – optional vector describing an additional root-power noise source proportional to the amplitude of the measured signal

Both noise sources are assumed to be Gaussian and independent. Specifying measurement errors with this function can improve accuracy and repeatability in the error term solution, especially for significantly overdetermined systems, as the 16 term models typically are.

et_tolerance

For iterative solution methods, this parameter controls the degree of change in the root-mean-squared of the error terms sufficiently small to stop iteration (float). Default is 1.0e-6.

p_tolerance

For iterative solution methods, this parameter controls the degree of change in the root-mean-squared of the unknown parameters sufficiently small to stop iteration (float). This parameter has no effect if there are no unknown parameters in the S matrix. Default is 1.0e-6.

iteration_limit

For iterative solution methods, this parameter controls the maximum number of iterations permitted to reach convergence (int). The default is 30.

pvalue_limit

p-value, below which to reject the null hypothesis that the measurement errors are less than or equal to the values given in set_m_error (float).

This parameter has no effect if measurement error modeling has not been enabled through set_m_error(). The default is 0.001.

solve()

Solve for the error terms. Note: if this function raises an exception due to an insufficient number of standards, you may add additional standards and try again.

add_to_calset(name) int

Add the solved calibration to the Calset. If name matches an existing calibration, the existing calibration is replaced; if name is unique, then the new calibration is appended to the Calset.calibrations array.

Parameters:

name – name for the calibration

Returns:

index of the new entry in Calset.calibrations

Embedding and De-embedding Network Parameter Data

Calset.embed_npdata(npdata: NPData, fixture) NPData

Embed network parameter data in a test fixture

Parameters:
  • npdata – an NPData object to embed

  • fixture – a ParameterMatrix or NPData object representing the test fixture. First port faces the VNA; second port faces the DUT.

Returns:

A new NPData object with the effect of the fixture added.

Calset.deembed_npdata(npdata: NPData, fixture) NPData

De-embed network parameter data in a test fixture

Parameters:
  • npdata – an NPData object to de-embed

  • fixture – a ParameterMatrix or NPData object representing the test fixture. First port faces the VNA; second port faces the DUT.

Returns:

A new NPData object with the effect of the fixture removed.

Metadata and Persistence

Calset.properties and Calibration.properties can be assigned arbitrary trees of nested lists, dictionaries, scalars and None values making it possible to save use-defined metadata with the calibrations. The save() function saves the Calset object to a file.

Calset.properties

Tree of nested dictionaries, lists, scalars and None values representing arbitrary user-defined metadata to be saved with the Calset. Examples might include model and serial number and capabilities of the instrument.

Also see the calibration-specific properties, Calibration.properties.

Calset.save(filename)

Save the Calset to a file.

Parameters:

filename (str) –

pathname of the save file

Note that the suggested file extension of .vnacal is not added automatically.