/Users/bernard/b20/bsoft/src/mg/mg_particles.cpp(3)

NAME
/Users/bernard/b20/bsoft/src/mg/mg_particles.cpp - Calculates centers of single particle images.

SYNOPSIS

#include 'mg_processing.h'
#include 'mg_particles.h'
#include 'mg_img_proc.h'
#include 'rwimg.h'
#include 'matrix_linear.h'
#include 'utilities.h'
#include 'timer.h'
#include <sys/stat.h>

  Functions
int project_align_particles (Bproject *project, int part_select, double nuavg, double nustd)
Aligns single particle images based on orientation parameters.
int project_center_particles (Bproject *project, int part_select, double nuavg, double nustd)
Centers single particle images based on the parametric center.
int project_set_particle_centers (Bproject *project, Bimage *pref, int part_select, double hires, double lores)
Calculates centers of single particle images by cross-correlation with a reference.
long project_find_part_centers_in_mgs (Bproject *project, double hires, double lores, int filter_flag)
Finds the centers of picked particles within a micrograph.
long mg_find_part_centers (Bmicrograph *mg, double hires, double lores, int filter_flag)
Finds the centers of picked particles within a micrograph.
Bimage * project_find_particle_centers (Bproject *project, int max_iter, int part_select, double hires, double lores)
Calculates centers of single particle images.
long particles_mask (Bmicrograph *mg, Bimage *pmask, Bstring &partpath)
long project_mask_particles (Bproject *project, Bimage *pmask, Bstring &partpath)
Calculates centers of single particle images.
long project_compare_particles (Bproject *project, Bproject *projcomp)
Compares the coordinates of particles between two files.
double project_tilt_from_particle_defocus (Bproject *project)
Finds the tilt axis from refined particle defocus values.
long project_set_particle_defocus_from_tilt (Bproject *project, double axis, double tilt)
Finds the tilt axis from refined particle defocus values.

  Variables
int verbose

Detailed Description

Calculates centers of single particle images.

Author:
    Bernard Heymann

Date:
    Created: 20080424

    Modified: 20180102

Definition in file mg_particles.cpp.

Function Documentation

  long mg_find_part_centers (Bmicrograph * mg, double hires, double lores, int filter_flag)

Finds the centers of picked particles within a micrograph.

Parameters:
    *mg micrograph parameter structure.
    hires high resolution limit.
    lores low resolution limit.
    filter_flag flag to filter extremes in particles.

Returns:
    long number of particles.

    An image processing parameter structure loaded with micrograph
    information is used to extract particle images from the micrograph
    image using the particle coordinates in the parameter structure.
    The extracted particle images are each rotated by PI and the shift
    found by cross-correlation between the unrotated and rotated images.
    The particle coordinates in the parameter structure are updated with
    the shift.

Definition at line 354 of file mg_particles.cpp.

  long particles_mask (Bmicrograph * mg, Bimage * pmask, Bstring & partpath)

Definition at line 512 of file mg_particles.cpp.

  int project_align_particles (Bproject * project, int part_select, double nuavg, double nustd)

Aligns single particle images based on orientation parameters.

Parameters:
    *project image processing parameter structure.
    part_select selection number from the selection column.
    nuavg rescale to new average.
    nustd rescale to new standard deviation.

Returns:
    int 0.

    Each selected particle image is rotated and shifted.

Definition at line 33 of file mg_particles.cpp.

  int project_center_particles (Bproject * project, int part_select, double nuavg, double nustd)

Centers single particle images based on the parametric center.

Parameters:
    *project image processing parameter structure.
    part_select selection number from the selection column.
    nuavg rescale to new average.
    nustd rescale to new standard deviation.

Returns:
    int 0.

    Each particle image is shifted to center the origin.

Definition at line 135 of file mg_particles.cpp.

  long project_compare_particles (Bproject * project, Bproject * projcomp)

Compares the coordinates of particles between two files.

Parameters:
    *project project parameter structure.
    *projcomp comparable project parameter structure.

Returns:
    long number of common particles.

    The coordinates of particles in one parameter file is compared to
    that of a reference parameter file.
    The two parameter files must have the same field and micrograph ID's.

Definition at line 650 of file mg_particles.cpp.

  long project_find_part_centers_in_mgs (Bproject * project, double hires, double lores, int filter_flag)

Finds the centers of picked particles within a micrograph.

Parameters:
    *project project parameter structure.
    hires high resolution limit.
    lores low resolution limit.
    filter_flag flag to filter extremes in particles.

Returns:
    int 0.

    An image processing parameter structure loaded with micrograph
    information is used to extract particle images from the micrograph
    image using the particle coordinates in the parameter structure.
    The extracted particle images are each rotated by PI and the shift
    found by cross-correlation between the unrotated and rotated images.
    The particle coordinates in the parameter structure are updated with
    the shift.

Definition at line 319 of file mg_particles.cpp.

  Bimage* project_find_particle_centers (Bproject * project, int max_iter, int part_select, double hires, double lores)

Calculates centers of single particle images.

Parameters:
    *project image processing parameter structure.
    max_iter maximum number of iterations.
    part_select selection number from the selection column.
    hires high resolution limit.
    lores low resolution limit.

Returns:
    Bimage* final image composite reference.

    A composite image is generated from the selected particles and radially
    symmetrized. Each image shift is then determined by cross correlation.
    This is repeated until the chnage in image shifts decreases below
    a threshold.

Definition at line 408 of file mg_particles.cpp.

  long project_mask_particles (Bproject * project, Bimage * pmask, Bstring & partpath)

Calculates centers of single particle images.

Parameters:
    *project image processing parameter structure.
    *pmask 3D volume mask to be projected.
    &partpath new path to particle files.

Returns:
    long number of particles masked.

    A 3D mask is projected into each particle view and the particle image masked.

Definition at line 579 of file mg_particles.cpp.

  int project_set_particle_centers (Bproject * project, Bimage * pref, int part_select, double hires, double lores)

Calculates centers of single particle images by cross-correlation with a reference.

Parameters:
    *project image processing parameter structure.
    *pref reference image.
    part_select selection number from the selection column.
    hires high resolution limit.
    lores low resolution limit.

Returns:
    int 0.

    Each particle image shift is determined by cross correlation with
    the reference image.
    The reference must be the same size as the particle images.

Definition at line 260 of file mg_particles.cpp.

  long project_set_particle_defocus_from_tilt (Bproject * project, double axis, double tilt)

Finds the tilt axis from refined particle defocus values.

Parameters:
    *project project parameter structure.
    axis tilt axis angle (radians).
    tilt tilt angle (radians).

Returns:
    long number of selected particles.

Definition at line 802 of file mg_particles.cpp.

  double project_tilt_from_particle_defocus (Bproject * project)

Finds the tilt axis from refined particle defocus values.

Parameters:
    *project project parameter structure.

Returns:
    double average tilt axis.

Definition at line 709 of file mg_particles.cpp.

Variable Documentation

  int verbose

Author

Generated automatically by Doxygen for Bsoft from the source code.