AFL.automation.instrument.OpticalTurbidity#

Functions

canny(image[, sigma, low_threshold, ...])

Edge filter an image using the Canny algorithm.

hough_circle(image, radius[, normalize, ...])

Perform a circular Hough transform.

hough_circle_peaks(hspaces, radii[, ...])

Return peaks in a circle Hough transform.

img_as_ubyte(image[, force_copy])

Convert an image to 8-bit unsigned integer format.

rgb2gray(rgb, *[, channel_axis])

Compute luminance of an RGB image.

Classes

Driver(name[, defaults, overrides, ...])

Eq(key, value)

Query equality of a given key's value to the specified value.

OpticalTurbidity([camera, overrides])

class AFL.automation.instrument.OpticalTurbidity.OpticalTurbidity(camera=None, overrides=None)[source]#
defaults = {'camera_index': 0, 'camera_interface': 'http', 'camera_url': 'http://afl-video:8081/103/current', 'col_crop': [0, 479], 'empty_uuid': '', 'hough_radii': 98, 'row_crop': [0, 479], 'save_path': '/home/afl642/2305_SINQ_TurbidityImages/'}#
__init__(camera=None, overrides=None)[source]#

Initialize OpticalTurbidity calculator driver.

Parameters:
  • camera (object, optional) – Camera object (for example, a NetworkCamera instance). If None, one will be created when using the HTTP interface.

  • overrides (dict, optional) – Configuration overrides for PersistentConfig.

measure(set_empty=False, plotting=False, **kwargs)[source]#

This is an optical turbidity measurement observing the SANS cell.

Parameters:
  • set_empty (bool, optional) – If True, set the current image as the empty reference image.

  • plotting (bool, optional) – If True, save diagnostic plots.

  • **kwargs (dict) – Additional arguments passed to image collection.

Returns:

Dataset with turbidity measurements and images. When set_empty=True, the dataset contains the captured empty image.

Return type:

xarray.Dataset