msl.examples.loadlib.labview32 module

A wrapper around a 32-bit LabVIEW library, labview_lib32.

Attention

This example requires that the appropriate LabVIEW Run-Time Engine is installed and that the operating system is Windows.

Example of a server that loads a 32-bit shared library, labview_lib, in a 32-bit Python interpreter to host the library. The corresponding labview64 module can be executed by a 64-bit Python interpreter and the Labview64 class can send a request to the Labview32 class which calls the 32-bit library to execute the request and then return the response from the library.

class msl.examples.loadlib.labview32.Labview32(host, port, **kwargs)

Bases: Server32

A wrapper around the 32-bit LabVIEW library, labview_lib32.

Parameters:
  • host (str) – The IP address (or hostname) to use for the server.

  • port (int) – The port to open for the server.

  • kwargs (str) – Optional keyword arguments. The keys and values are of type str.

stdev(x, weighting=0)

Calculates the mean, variance and standard deviation of the values in the input x.

See the corresponding 64-bit stdev() method.

Parameters:
  • x (Sequence[float]) – The data to calculate the mean, variance and standard deviation of.

  • weighting (int) – Whether to calculate the sample (weighting = 0) or the population (weighting = 1) standard deviation and variance.

Returns:

The mean, variance and standard deviation.

Return type:

tuple[float, float, float]