Function Reference

This page provides a comprehensive reference of all functions available in the findpeaks library, organized by category for easy navigation.

Core Functions

Main findpeaks class functions

Function

Description

findpeaks.findpeaks.findpeaks()

Main class for peak detection and analysis

findpeaks.findpeaks.findpeaks.__init__()

Initialize the findpeaks object with detection parameters

findpeaks.findpeaks.findpeaks.fit()

Fit the peak detection model to the input data

findpeaks.findpeaks.findpeaks.peaks1d()

Detect peaks and valleys in 1D data

findpeaks.findpeaks.findpeaks.peaks2d()

Detect peaks and valleys in 2D data (images)

findpeaks.findpeaks.findpeaks.preprocessing()

Apply preprocessing pipeline to the input data

findpeaks.findpeaks.findpeaks.import_example()

Import example datasets for testing and demonstration

Visualization Functions

Plotting and visualization functions

Function

Description

findpeaks.findpeaks.findpeaks.plot()

Main plotting function for comprehensive results visualization

findpeaks.findpeaks.findpeaks.plot1d()

Plot results for 1D data analysis

findpeaks.findpeaks.findpeaks.plot2d()

Plot results for 2D data analysis

findpeaks.findpeaks.findpeaks.plot_persistence()

Plot persistence diagrams for topology method

findpeaks.findpeaks.findpeaks.plot_mesh()

Create 3D mesh visualizations

findpeaks.findpeaks.findpeaks.plot_preprocessing()

Visualize preprocessing pipeline steps

findpeaks.findpeaks.findpeaks.plot_mask()

Plot masking results with customizable font size

Peak Detection Methods

Core detection algorithms

Function

Description

findpeaks.stats.topology()

Topology-based peak detection using persistent homology

findpeaks.stats.topology2d()

2D topology-based peak detection

findpeaks.peakdetect.peakdetect()

Traditional peak detection algorithm

findpeaks.stats.mask()

Mask-based local maximum filtering for 2D data

findpeaks.stats.caerus()

Caerus method for financial time series analysis

Preprocessing Functions

Data preprocessing and transformation functions

Function

Description

findpeaks.interpolate.interpolate_line1d()

1D data interpolation with multiple methods

findpeaks.interpolate.interpolate_line2d()

2D data interpolation for x,y coordinates

findpeaks.stats.resize()

Resize 2D arrays (images) using OpenCV

findpeaks.stats.scale()

Scale data to specified range

findpeaks.stats.togray()

Convert images to grayscale

findpeaks.stats.denoise()

Apply various denoising filters to images

Denoising Filters

Image denoising filter functions

Function

Description

findpeaks.filters.lee.lee_filter()

Lee filter for additive noise reduction

findpeaks.filters.lee_enhanced.lee_enhanced_filter()

Enhanced Lee filter with improved edge preservation

findpeaks.filters.lee_sigma.lee_sigma_filter()

Lee Sigma filter for adaptive noise reduction

findpeaks.filters.frost.frost_filter()

Frost filter for multiplicative noise reduction

findpeaks.filters.kuan.kuan_filter()

Kuan filter for speckle noise reduction

findpeaks.filters.mean.mean_filter()

Mean filter for noise smoothing

findpeaks.filters.median.median_filter()

Median filter for noise reduction while preserving edges

Utility Functions

Utility and helper functions

Function

Description

findpeaks.stats._make_unique()

Make array elements unique with progress tracking

findpeaks.union_find.UnionFind()

Union-find data structure for connected components

findpeaks.filters.lee_enhanced.assert_parameters()

Validate parameters for enhanced Lee filter

Function Categories by Use Case

Functions organized by common use cases

Use Case

Relevant Functions

1D Signal Analysis

findpeaks.findpeaks.findpeaks.peaks1d(), findpeaks.stats.topology(), findpeaks.peakdetect.peakdetect(), findpeaks.interpolate.interpolate_line1d(), findpeaks.findpeaks.findpeaks.plot1d()

2D Image Analysis

findpeaks.findpeaks.findpeaks.peaks2d(), findpeaks.stats.mask(), findpeaks.stats.topology2d(), findpeaks.stats.resize(), findpeaks.stats.togray(), findpeaks.findpeaks.findpeaks.plot2d()

Financial Time Series

findpeaks.stats.caerus(), findpeaks.findpeaks.findpeaks.fit(), findpeaks.findpeaks.findpeaks.plot()

SAR Image Processing

findpeaks.stats.denoise(), findpeaks.filters.lee.lee_filter(), findpeaks.filters.frost.frost_filter(), findpeaks.filters.kuan.kuan_filter(), findpeaks.stats.scale()

Data Visualization

findpeaks.findpeaks.findpeaks.plot_persistence(), findpeaks.findpeaks.findpeaks.plot_mesh(), findpeaks.findpeaks.findpeaks.plot_preprocessing(), findpeaks.findpeaks.findpeaks.plot_mask()

Data Preprocessing

findpeaks.findpeaks.findpeaks.preprocessing(), findpeaks.interpolate.interpolate_line1d(), findpeaks.interpolate.interpolate_line2d(), findpeaks.stats.resize(), findpeaks.stats.scale()

Quick Reference by Method

Functions grouped by detection method

Method

Functions

Topology

findpeaks.stats.topology(), findpeaks.stats.topology2d(), findpeaks.findpeaks.findpeaks.plot_persistence()

Peakdetect

findpeaks.peakdetect.peakdetect(), findpeaks.findpeaks.findpeaks.peaks1d()

Mask

findpeaks.stats.mask(), findpeaks.findpeaks.findpeaks.peaks2d(), findpeaks.findpeaks.findpeaks.plot_mask()

Caerus

findpeaks.stats.caerus(), findpeaks.findpeaks.findpeaks.fit()

Interpolation

findpeaks.interpolate.interpolate_line1d(), findpeaks.interpolate.interpolate_line2d()

Denoising

findpeaks.stats.denoise(), findpeaks.filters.lee.lee_filter(), findpeaks.filters.frost.frost_filter(), findpeaks.filters.kuan.kuan_filter(), findpeaks.filters.mean.mean_filter(), findpeaks.filters.median.median_filter()