mean_squared_error#
- ctapipe.image.muon.mean_squared_error(pixel_fov_lon: Quantity, pixel_fov_lat: Quantity, weights: Quantity | ndarray | Sequence[float], ring: MuonRingContainer) float[source]#
 Calculate the weighted mean squared error for a circle.
- Parameters:
 - pixel_fov_lonQuantity
 Longitudes (x-coordinates) of the camera pixels in the TelescopeFrame.
- pixel_fov_latQuantity
 Latitudes (y-coordinates) of the camera pixels in the TelescopeFrame.
- weightsQuantity | np.ndarray | Sequence[float]
 Weights for the camera pixels, usually the photoelectron charges.
- ringMuonRingContainer
 Container with the fitted ring parameters, including center coordinates and radius.
- Returns:
 - float
 The weighted mean squared error of the pixels around the fitted ring.
Notes
This function calculates the weighted mean squared error of the pixels around the fitted ring by determining the radial distance of each pixel from the ring center and comparing it to the ring radius. The mean squared error is weighted by the pixel intensities.