colocalization#

class ColocalizationProcessor(sample_manager: SampleManager | None = None, config_coordinator: ConfigCoordinator | None = None, channels: List[str] | None = None, registration_processor: RegistrationProcessor | None = None)[source]#

Bases: CompoundChannelPipelineOrchestrator

compute_colocalization(channel_a, channel_b)[source]#
filter_table(channel_a, channel_b)[source]#
finalise_setup()[source]#
get_cells_df(channel)[source]#
get_voxelization_params(channel_a, channel_b)[source]#
plot_nearest_neighbors(channel_a, channel_b, parent=None)[source]#
plot_overlaps()[source]#
save_filtered_table(channel_a, channel_b)[source]#
setup(sample_manager: SampleManager | None, channel_names: tuple[str], registration_processor: RegistrationProcessor | None = None)[source]#

Attach a sample manager and mark this processor as ready.

Parameters:

sample_manager (SampleManager, optional) – If provided, replaces the currently stored sample manager. When None, the previously stored instance is reused.

Raises:

ValueError – If the config section identified by config_name is absent.

voxelize_filtered_table(channel_a, channel_b)[source]#
voxelize_unweighted(channel_a, channel_b, coordinates, voxelization_parameter)[source]#

Voxelize un weighted i.e. for cell counts

Parameters:
  • channel_a (str) – Name of the first channel

  • channel_b (str) – Name of the second channel

  • coordinates (str, array or Source) – Source of point of nxd coordinates.

  • voxelization_parameter (dict) –

    Dictionary to be passed to voxelization.voxelise (i.e. with these optional keys:

    shape, dtype, weights, method, radius, kernel, processes, verbose

Returns

coordinates, counts_file_path: np.array, str

colocalization_channels: dict[Channel]#
config_name = 'colocalization'#