AllenInstitute / brain_observatory_qc

Other
2 stars 0 forks source link

Saturation Metric (number of saturated pixels) only checks first 500 frames #385

Open seanmcculloch opened 8 months ago

seanmcculloch commented 8 months ago

Metric / Plot Impacted

Update Motivation This metric currently only uses the first few minutes to create a max projection, then count's the number of saturated pixels in that max projection. This should be changed to use more of the session - especially since this time period may not account for periods in the session with stronger activity

The threshold should also be reevaluated for this metric.

Currently, the threshold is set to flag at 800px, fail at 1000px. We believe this was set to roughly estimate the number of pixels in a single cell. (Failure if an entire cell is saturated at any point).

The function for this metric is here: https://github.com/AllenInstitute/mindscope_qc_metrics/blob/ad301d9524ca89b8ee210621e0be81de76b62f6e/mindscope_qc_metrics/datasets/motion_corr_physio.py#L483

Note the default parameter "end_frame" set to 500.

This has implications on recalculating a large backlog of saturation metrics that was previously discussed.

seanmcculloch commented 8 months ago

Description of motion_corr_physio Metrics used in reports:

Physio intensity values histogram (physio_intensity_hist)

Number saturated pixels (physio_nb_saturated_pixels)

Motion corrected physio mean intensity (physio_video_mean)

Maximum Intensity Projection (maximum_intensity_projection_image)

Intensity drift (%) (physio_percent_change_intensity)

Frame Intensity Std. (physio_frame_intensity_std)

Physio intensity timeseries (physio_intensity_plot)

Epilepsy Probability (%) (epilepsy_probability)

Epilepsy Probability Plot (epilepsy_probability_plot)

Number excessive motion frames (nb_excessive_motion_frames)

XY motion plot (xy_motion_plot)

XY motion histogram (motion_histogram)

Motion correction, Max Total Shift (max_total_shift)

Motion correction, mean total shift (mean_total_shift)

seanmcculloch commented 8 months ago

Explore nb_saturated_pixels by seeing how it changes for each 500frames of the movie

seanmcculloch commented 8 months ago

ping QC stakeholders teams channel

seanmcculloch commented 8 months ago

Run backlog of saturation metrics with current metric