![]() |
Bsoft 2.1.4
Bernard's software package
|
Analyzes and manipulates single particle images. More...
#include "mg_processing.h"
#include "mg_particles.h"
#include "mg_particle_select.h"
#include "mg_select.h"
#include "mg_img_proc.h"
#include "mg_ctf.h"
#include "rwimg.h"
#include "matrix_linear.h"
#include "file_util.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. More... | |
int | project_center_particles (Bproject *project, int part_select, double nuavg, double nustd) |
Centers single particle images based on the parametric center. More... | |
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. More... | |
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. More... | |
long | mg_find_part_centers (Bmicrograph *mg, double hires, double lores, int filter_flag) |
Finds the centers of picked particles within a micrograph. More... | |
Bimage * | project_find_particle_centers (Bproject *project, int max_iter, int part_select, double hires, double lores) |
Calculates centers of single particle images. More... | |
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. More... | |
long | project_compare_particles (Bproject *project, Bproject *projcomp) |
Compares the coordinates of particles between two files. More... | |
double | project_tilt_from_particle_defocus (Bproject *project) |
Finds the tilt axis from refined particle defocus values. More... | |
long | project_set_particle_defocus_from_tilt (Bproject *project, double axis, double tilt) |
Finds the tilt axis from refined particle defocus values. More... | |
Bimage * | particle_correlation_sum (Bparticle *part, Bimage *pref, double hires, FSI_Kernel *kernel, fft_plan planf) |
Bimage * | project_correlation_sum (Bproject *project, Bimage *pref, double hires, FSI_Kernel *kernel) |
Correlates each particle with the CTF applied reference projection and sum the correlations. More... | |
int | img_add_aberration_terms (Bimage *psum, Bimage *psec, Bimage *ppart, CTFparam &cp) |
Bimage * | particle_aberration_sum (Bparticle *part, Bimage *pref, double hires, FSI_Kernel *kernel, fft_plan planf) |
int | img_check_contrast (Bimage *psum) |
Bimage * | img_calculate_phase_differences (Bimage *psum) |
Bimage * | project_aberration_phase_difference (Bproject *project, Bimage *pref, double hires, FSI_Kernel *kernel) |
Calculates the aberration phase difference from a set of particles. More... | |
Variables | |
int | verbose |
Analyzes and manipulates single particle images.
int img_check_contrast | ( | Bimage * | psum | ) |
long mg_find_part_centers | ( | Bmicrograph * | mg, |
double | hires, | ||
double | lores, | ||
int | filter_flag | ||
) |
Finds the centers of picked particles within a micrograph.
*mg | micrograph parameter structure. |
hires | high resolution limit. |
lores | low resolution limit. |
filter_flag | flag to filter extremes in 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.
Bimage * particle_aberration_sum | ( | Bparticle * | part, |
Bimage * | pref, | ||
double | hires, | ||
FSI_Kernel * | kernel, | ||
fft_plan | planf | ||
) |
Bimage * particle_correlation_sum | ( | Bparticle * | part, |
Bimage * | pref, | ||
double | hires, | ||
FSI_Kernel * | kernel, | ||
fft_plan | planf | ||
) |
long particles_mask | ( | Bmicrograph * | mg, |
Bimage * | pmask, | ||
Bstring & | partpath | ||
) |
Bimage * project_aberration_phase_difference | ( | Bproject * | project, |
Bimage * | pref, | ||
double | hires, | ||
FSI_Kernel * | kernel | ||
) |
Calculates the aberration phase difference from a set of particles.
*project | project parameter structure. |
*pref | reference map. |
hires | high resolution limit (angstrom). |
*kernel | frequency space interpolation kernel lookup table. |
Uses the method as described in Zivanov et al (2020). The return image is complex with the even and odd phase differences in real and imaginary parts, respectively.
int project_align_particles | ( | Bproject * | project, |
int | part_select, | ||
double | nuavg, | ||
double | nustd | ||
) |
Aligns single particle images based on orientation parameters.
*project | micrograph processing parameter structure. |
part_select | selection number from the selection column. |
nuavg | rescale to new average. |
nustd | rescale to new standard deviation. |
Each selected particle image is rotated and shifted.
int project_center_particles | ( | Bproject * | project, |
int | part_select, | ||
double | nuavg, | ||
double | nustd | ||
) |
Centers single particle images based on the parametric center.
*project | micrograph processing parameter structure. |
part_select | selection number from the selection column. |
nuavg | rescale to new average. |
nustd | rescale to new standard deviation. |
Each particle image is shifted to center the origin.
Compares the coordinates of particles between two files.
*project | project parameter structure. |
*projcomp | comparable project parameter structure. |
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.
Bimage * project_correlation_sum | ( | Bproject * | project, |
Bimage * | pref, | ||
double | hires, | ||
FSI_Kernel * | kernel | ||
) |
Correlates each particle with the CTF applied reference projection and sum the correlations.
*project | project parameter structure. |
*pref | reference map. |
hires | high resolution limit (angstrom). |
*kernel | frequency space interpolation kernel lookup table. |
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.
*project | project parameter structure. |
hires | high resolution limit. |
lores | low resolution limit. |
filter_flag | flag to filter extremes in 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.
Bimage * project_find_particle_centers | ( | Bproject * | project, |
int | max_iter, | ||
int | part_select, | ||
double | hires, | ||
double | lores | ||
) |
Calculates centers of single particle images.
*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. |
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.
Calculates centers of single particle images.
*project | image processing parameter structure. |
*pmask | 3D volume mask to be projected. |
&partpath | new path to particle files. |
A 3D mask is projected into each particle view and the particle image masked.
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.
*project | micrograph processing parameter structure. |
*pref | reference image. |
part_select | selection number from the selection column. |
hires | high resolution limit. |
lores | low resolution limit. |
Each particle image shift is determined by cross correlation with the reference image. The reference must be the same size as the particle images.
long project_set_particle_defocus_from_tilt | ( | Bproject * | project, |
double | axis, | ||
double | tilt | ||
) |
Finds the tilt axis from refined particle defocus values.
*project | project parameter structure. |
axis | tilt axis angle (radians). |
tilt | tilt angle (radians). |
double project_tilt_from_particle_defocus | ( | Bproject * | project | ) |
Finds the tilt axis from refined particle defocus values.
*project | project parameter structure. |
|
extern |