owl.calibration¶
- owl.calibration.calculate_led_for_desired_pixel(response_matrix, pixels)[source]¶
Gives led values that will produce the given pixel ratio.
- Parameters:
response_matrix (numpy array) – Array of float that model the responses of the sensors. The array is shape (image_y, image_x, 4, 4).
pixels (tuple) – Ratio of the desired pixel values. It must be length 3.
- Returns:
led_values – The values of led values to produce near the desired pixel values on white paper.
- Return type:
- owl.calibration.create_pixel_corrections(coefficient_polynomial_coefficients, offset_polynomial_coefficients, *, image_shape, tqdm=<function tqdm>)[source]¶
Create a coefficient and offset pixel correction based on the polynomial coefficients.
- Parameters:
coefficient_polynomial_coefficients (numpy array) – An MxNx4x4 array of polynomial coefficients describing the pixel coefficient corrections.
offset_polynomial_coefficients (numpy array) – An MxNx4x4 array of polynomial coefficients describing the pixel offset corrections.
image_shape (tuple) – The desired shape of the images in pixel (y_pixels, x_pixels).
tqdm (optional) – Progress-bar callable used to wrap the per-camera loop.
- Returns:
coefficient_corrections (numpy array) – Array of pixel correction coefficients of shape M x N x image_shape.
offset_corrections (numpy array) – Array of pixel correction offsets of shape M x N x image_shape.