IMP logo
IMP Reference Guide  develop.d36d3deffb,2026/11/09
The Integrative Modeling Platform
image_processing.h File Reference

Image processing functions. More...

#include <IMP/em2d/em2d_config.h>
#include "IMP/em2d/PolarResamplingParameters.h"
#include "IMP/em2d/Matrix.h"
#include "IMP/base_types.h"
#include <algorithm>
#include <cmath>
#include <cereal/access.hpp>
+ Include dependency graph for image_processing.h:
+ This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

class  IMP::em2d::MatchTemplateResult
 
class  IMP::em2d::SegmentationParameters
 Class to provide all the parameters to the segmentation function. More...
 

Namespaces

 IMP
 Base functionality and abstract base classes for representation, scoring and sampling.
 
 IMP::em2d
 Restraints using electron microscopy 2D images (class averages).
 

Typedefs

typedef IMP::Vector
< MatchTemplateResult > 
IMP::em2d::MatchTemplateResults
 
typedef IMP::Vector
< SegmentationParameters > 
IMP::em2d::SegmentationParametersList
 

Functions

void IMP::em2d::add_noise (DoubleMatrix &v, double op1, double op2, const String &mode="uniform", double df=3)
 Add noise to the values of a matrix. More...
 
void IMP::em2d::apply_circular_mask (const DoubleMatrix &mat, DoubleMatrix &result, int radius, double value=0.0)
 
void IMP::em2d::apply_diffusion_filter (const DoubleMatrix &m, DoubleMatrix &result, double beta, double pixelsize, unsigned int time_steps)
 
void IMP::em2d::apply_mask (const DoubleMatrix &m, DoubleMatrix &result, const IntMatrix &mask, double val)
 Applies a binary mask to an image. More...
 
void IMP::em2d::apply_threshold (DoubleMatrix &m, DoubleMatrix &result, double threshold=0.0)
 
void IMP::em2d::apply_variance_filter (const DoubleMatrix &input, DoubleMatrix &filtered, int kernelsize)
 
IntMatrix IMP::em2d::create_circular_mask (int rows, int cols, int radius)
 
DoubleMatrix IMP::em2d::crop (const DoubleMatrix &m, const IntPair &center, int size)
 
void IMP::em2d::do_combined_fill_holes_and_threshold (DoubleMatrix &m, DoubleMatrix &result, double n_stddevs, double threshold=0.0)
 Combines the fill holes and thresholding operations together with normalize. More...
 
void IMP::em2d::do_dilate_and_shrink_warp (DoubleMatrix &m, const DoubleMatrix &grayscale, DoubleMatrix &kernel)
 (U. Adiga, 2005) More...
 
void IMP::em2d::do_extend_borders (const DoubleMatrix &orig, DoubleMatrix &dst, unsigned int pix)
 
void IMP::em2d::do_fill_holes (const DoubleMatrix &m, DoubleMatrix &result, double h)
 Fills the holes in the matrix m of height h. More...
 
void IMP::em2d::do_histogram_stretching (DoubleMatrix &m, int boxes, int offset)
 
int IMP::em2d::do_labeling (const IntMatrix &m, IntMatrix &mat_to_label)
 Labeling function for a matrix. More...
 
void IMP::em2d::do_morphologic_contrast_enhancement (const DoubleMatrix &m, DoubleMatrix &result, const DoubleMatrix &kernel, unsigned int iterations)
 
void IMP::em2d::do_morphologic_reconstruction (const DoubleMatrix &mask, DoubleMatrix &marker, int neighbors_mode=4)
 morphologic grayscale reconstruction (L Vincent, 1993) More...
 
void IMP::em2d::do_normalize (DoubleMatrix &m)
 Normalize a matrix to mean 0 and stddev 1. It is done in place. More...
 
void IMP::em2d::do_remove_small_objects (IntMatrix &m, double percentage, int background=0, int foreground=1)
 Removes small objects from a matrix of integers. More...
 
void IMP::em2d::do_resample_polar (const DoubleMatrix &input, DoubleMatrix &resampled, const PolarResamplingParameters &polar_params)
 Resamples a matrix to polar coordinates. More...
 
void IMP::em2d::do_segmentation (const DoubleMatrix &m, DoubleMatrix &result, const SegmentationParameters &params)
 Segmentation of images. More...
 
MatchTemplateResults IMP::em2d::get_best_template_matches (const DoubleMatrix &m, const DoubleMatrix &templ, unsigned int n)
 
void IMP::em2d::get_diffusion_filtering_partial_derivative (const DoubleMatrix &m, DoubleMatrix &der, double dx, double dy, double ang)
 
void IMP::em2d::get_domes (DoubleMatrix &m, DoubleMatrix &result, double h)
 Gets the domes of m with height h. More...
 
Floats IMP::em2d::get_histogram (const DoubleMatrix &m, int bins)
 Computes the histogram of a matrix. More...
 
double IMP::em2d::get_mean (const DoubleMatrix &mat, const IntMatrix &mask)
 
void IMP::em2d::get_morphologic_gradient (const DoubleMatrix &m, DoubleMatrix &result, const DoubleMatrix &kernel)
 
double IMP::em2d::get_overlap_percentage (DoubleMatrix &m1, DoubleMatrix &m2, const IntPair &center)
 
void IMP::em2d::get_transformed (const DoubleMatrix &input, DoubleMatrix &transformed, const algebra::Transformation2D &T)
 

Detailed Description

Image processing functions.

Copyright 2007-2026 IMP Inventors. All rights reserved.

Definition in file image_processing.h.