PeakCaller#

class PeakCaller(shape, num_peaks=1000, min_distance=1, min_boundary_distance=0, min_score=None, max_score=None, batch_dims=None, shm_handler=None, **kwargs)[source]#

Bases: AbstractAnalyzer

Base class for peak calling algorithms.

Parameters:
shapetuple of int

Score space shape. Used to determine dimension of peak calling problem.

num_peaksint, optional

Number of candidate peaks to consider.

min_distanceint, optional

Minimum distance between peaks, 1 by default

min_boundary_distanceint, optional

Minimum distance to array boundaries, 0 by default.

min_scorefloat, optional

Minimum score from which to consider peaks.

max_scorefloat, optional

Maximum score upon which to consider peaks.

batch_dimsint, optional

Peak calling batch dimensions.

**kwargs

Optional keyword arguments.

Raises:
ValueError

If num_peaks is less than or equal to zero. If min_distances is less than zero.

Attributes

PeakCaller.shareable

Indicate whether the analyzer can be shared across processes.

Methods

PeakCaller.__call__(state, scores, ...)

Update the internal parameter store based on input array.

PeakCaller.call_peaks(scores, **kwargs)

Call peaks in the score space.

PeakCaller.init_state()

Initialize the analyzer state.

PeakCaller.merge([results])

Merge multiple instances of PeakCaller.

PeakCaller.oversample_peaks(scores, ...[, ...])

Refines peaks positions in the corresponding score space.

PeakCaller.result(state[, fast_shape, ...])

Finalize the analysis result with optional postprocessing.