 |
ImageD
v2_7_5 (24.06.22)
ImageD is an image processing software designed for rapid prototyping and implementing algorithms and solutions for science, research and teaching.
|
Go to the documentation of this file.
9 #ifndef D_MAKRO_IONTRACKS_H
10 #define D_MAKRO_IONTRACKS_H
26 #include <QMainWindow>
27 #include <QFileDialog>
29 #include <QFileInfoList>
33 #include <QCloseEvent>
34 #include <QResizeEvent>
35 #include <QInputDialog>
49 #include <opencv2/core/core.hpp>
50 #include <opencv2/highgui/highgui.hpp>
51 #include <opencv2/imgproc/imgproc.hpp>
70 void closeEvent(QCloseEvent *event);
71 void resizeEvent(QResizeEvent *event);
77 void Update_View_Proc();
80 void Update_ImgProc();
81 void Update_ImgProc_Proc(
int start_step);
82 void Update_Step_Proc(
int img,
int step);
85 void Calc_ValueDistribution();
86 void Calc_Track_Stats();
87 void Calc_Stack_Stats_All();
89 void Update_Results();
91 void Plot_StatAtRadius_All();
92 void Plot_StatAtRadius_All_Group();
93 void Plot_MeanSD_All();
94 void Plot_MedianADM_All();
95 void Plot_Quantiles_All();
97 void Table_SingleTrack();
98 void Table_TrackStats();
100 void Image_ColorRGB_Info();
102 void Update_Dimensions();
103 void Init_ImageVectors();
105 void Populate_CB_Single(QComboBox *CB, QStringList QSL);
106 void Populate_CB_All();
107 void Populate_CB_Stats();
108 void Populate_CB_AxeTrans();
109 void Populate_CB_PlotTypes();
110 void Populate_CB_TableTypes();
111 void Populate_CB_Dimensions();
112 void Populate_CB_Groups();
113 void Populate_CB_ProcSteps();
114 void Populate_CB_ImageRGB_Info();
116 void Load_DirectoriesList();
117 void Load_Directoty();
119 void Save_Analysis();
122 void Save_Plot(QString path);
124 void on_spinBox_ProcSet_Blur_Size_valueChanged(
int arg1);
125 void on_doubleSpinBox_ProcSet_Blur_Sigma_valueChanged(
double arg1);
126 void on_doubleSpinBox_ProcSet_Binarization_Thres_valueChanged(
double arg1);
127 void on_doubleSpinBox_ProcSet_ExLarge_MaxArea_valueChanged(
double arg1);
128 void on_doubleSpinBox_ProcSet_ExAsphere_MinSphere_valueChanged(
double arg1);
129 void on_spinBox_ProcSet_SafetyDist_MinRadius_valueChanged(
int arg1);
130 void on_doubleSpinBox_ProcSet_ExConn_MinSphere_valueChanged(
double arg1);
131 void on_doubleSpinBox_ProcSet_TOI_RelRadius_valueChanged(
double arg1);
133 void on_comboBox_ResTab_Group_currentIndexChanged(
int index);
135 void on_comboBox_ResPlo_Group_currentIndexChanged(
int index);
139 Ui::D_MAKRO_IonTracks *ui;
140 bool ClosingPossible =
false;
146 vector<vector<Mat>> vvMA_Proc_ImgStep;
147 vector<D_Value_Distribution_List> vVD_ValDistLists_Img;
150 vector<vector<vector<double>>> vvvd_All_StaRadTra;
151 vector<vector<vector<double>>> vvvd_All_StaStaRad;
153 vector<vector<vector<vector<double>>>> vvvvd_Lat_DimStaRadTra;
154 vector<vector<vector<vector<double>>>> vvvvd_Lat_DimStaStaRad;
156 vector<vector<vector<vector<double>>>> vvvvd_Dep_DimStaRadTra;
157 vector<vector<vector<vector<double>>>> vvvvd_Dep_DimStaStaRad;
160 bool calced_ImgProc =
false;
161 bool calced_ValDist =
false;
162 bool calced_StaTra =
false;
163 bool calced_StaSta =
false;
170 QChartView *pChartView_Plot;
176 int Dim_XLat_Dim = 2;
177 int Dim_YLat_Dim = 2;
178 int Dim_ZDep_Dim = 20;
181 double Dim_XLat_Step = 100.0;
182 double Dim_YLat_Step = 100.0;
183 double Dim_ZDep_Step = 5.0;
184 QString Dim_Unit =
"µm";
185 QStringList QSL_Dim_Lat;
186 QStringList QSL_Dim_Dep;
187 int Index_CurrentView();
188 void Update_Max_Radius();
193 QDir DIR_MasterDirectory;
194 QStringList QSL_ImageDirectories;
195 QStringList QSL_ImageDirectories_Names;
197 QFileInfoList FIL_InputCurrentSet;
198 QString QS_CurrentSetName;
199 QDir DIR_SaveAnalysis_Master;
200 QDir DIR_SaveAnalysis_Current;
204 void ERR(
int err, QString func =
"not specified", QString detail =
"not specified");
208 QStringList QSL_Radius;
226 QStringList QSL_ProcStepSingle =
231 "03 - Exclude Large",
232 "04 - Exclude Aspheres",
233 "05 - Safety Distance",
234 "06 - Exclude Connected",
235 "07 - Tracks of Interest",
252 c_PLO_STAT_AT_RADIUS,
256 c_PLO_STAT_AT_RADIUS_ALL,
259 QStringList QSL_PlotTypes =
262 "Mean and standard deviation",
263 "Median and average absolute deviation from median",
265 "Stat at radius (grouped)"
274 QStringList QSL_TableTypes =
277 "Statistics for all Tracks"
287 QStringList QSL_GroupsResolution =
302 c_IMG_SAPHETY_RADIUS,
305 QStringList QSL_ImageInfoRGB =
308 "Tracks of Interest",
317 #endif // D_MAKRO_IONTRACKS_H
@ c_AXE_POLAR_RADIUS
Definition: d_enum.h:2144
cv::Mat Mat
Definition: d_opencv_typedefs.h:28
void Update_View()
D_Viewer::Update_View Starts the workflow to show an image.
Definition: d_viewer.cpp:2096
@ c_AXE_TRANS_LOG_10
Definition: d_enum.h:2160
@ c_STAT_QUANTIL_80
Definition: d_enum.h:770
@ c_STAT_MINIMUM
Definition: d_enum.h:754
static int Feature_Select(Mat *pMA_Out, Mat *pMA_In, int feature, double f_min, double f_max, int connectivity=4)
Definition: d_img_proc.cpp:15710
const QStringList QSL_AxeTrans_x
Definition: d_enum.h:2165
static int Load_From_Path(Mat *pMA_Out, QFileInfo FI_path)
Definition: d_img_proc.cpp:16
The D_Viewer class Display images (Mat) in QGraphicsView in the user interface.
Definition: d_viewer.h:58
The D_Storage class Used for storing data. There is only one instance in D_MainWindow .
Definition: d_storage.h:49
@ ER_size_missmatch
Definition: d_enum.h:141
static int Normalize(Mat *pMA_Out, Mat *pMA_In, unsigned int norm, unsigned int type, double min, double max)
Definition: d_img_proc.cpp:3814
void Update_Image(Mat *MA_new)
D_Viewer::Update_Image Set and show image.
Definition: d_viewer.cpp:2079
@ c_STAT_ABS_DEV_MED
Definition: d_enum.h:775
Definition: d_makro_iontracks.h:63
@ c_AXE_TRANS_LIN
Definition: d_enum.h:2157
QString Save_Table()
Definition: d_table.cpp:186
static int Labeling(Mat *pMA_Out, Mat *pMA_In, int connectivity, int out_depth)
Definition: d_img_proc.cpp:12350
void set_TW(QTableWidget *TW)
Definition: d_table.cpp:16
void ERR(int err, QString sender, QString func, QString detail)
D_Error_Handler::ERR pops an error message if an error occured and/or streams it to a csv file.
Definition: d_error_handler.cpp:23
@ c_STAT_MAXIMUM
Definition: d_enum.h:774
static int Duplicate(Mat *pMA_Out, Mat *pMA_In)
Definition: d_img_proc.cpp:2397
void set_ClosingPossible(bool closeable)
Definition: d_makro_iontracks.h:72
@ c_STAT_QUANTIL_60
Definition: d_enum.h:766
void closeEvent(QCloseEvent *event)
Definition: d_makro_iontracks.cpp:111
void resizeEvent(QResizeEvent *event)
Definition: d_makro_iontracks.cpp:127
@ c_GEO_CENTROID
Definition: d_enum.h:2049
static int Threshold_Relative_1C(Mat *pMA_Out, Mat *pMA_In, double max_val, double thres_rel)
Definition: d_img_proc.cpp:6352
@ c_STAT_STAN_DEV_TOTAL
Definition: d_enum.h:750
@ c_STAT_MEDIAN
Definition: d_enum.h:764
The D_Table class Display tables in QTableWidget in the user interface.
Definition: d_table.h:42
The D_Error_Handler class takes error codes from D_ERROR_ENUM and shows a popup if an error occures.
Definition: d_error_handler.h:38
static int Plot_Line_XY_Multi(QChartView *pChartView, vector< vector< double >> vv_XY_Data, QString name_title, QString name_series, QString name_x, QString name_y, int x_trans=c_AXE_TRANS_LIN, int y_trans=c_AXE_TRANS_LIN, bool dots_visible=false, bool heat_color=false, bool heat_color_AllColors=false, Qt::Alignment legend_pos=Qt::AlignTop)
void set_data_d_2D_qsl_qsl(vector< vector< double >> vv_data, QStringList qsl_col_names, QStringList qsl_row_names)
Definition: d_table.cpp:74
const int MORPH_DILATE
Definition: d_opencv_typedefs.h:88
@ c_STAT_QUANTIL_40
Definition: d_enum.h:762
@ c_STAT_QUANTIL_20
Definition: d_enum.h:758
void clear_data()
Definition: d_table.cpp:148
@ c_FEAT_SPHERICITY
Definition: d_enum.h:1323
void set_GV(QGraphicsView *GV_ui)
Definition: d_viewer.cpp:49
const QStringList QSL_AxeTrans_y
Definition: d_enum.h:2173
static int Plot_Empty(QChartView *pChartView, QString QS_Text="No_Additional_Information")
Definition: d_plot.cpp:16
Definition: d_analysiswindow.h:58
QDir * dir_M_IonTracks()
Definition: d_storage.h:79
static int Morphology_Elemental(Mat *pMA_Out, Mat *pMA_In, int morph_type, int elem_type, unsigned int elem_size_X, unsigned int elem_size_Y, int border_type, unsigned int iterations)
Definition: d_img_proc.cpp:7041
@ c_AXE_TRANS_1pXX
Definition: d_enum.h:2162
static int Reduce_Outlines(Mat *pMA_Out, Mat *pMA_In, int neighborhood=8, int thickness=1)
Definition: d_img_proc.cpp:16469
const int MORPH_ELLIPSE
Definition: d_opencv_typedefs.h:87
static int Plot_Line_XY_Single(QChartView *pChartView, vector< double > v_XY_Data, QString name_title, QString name_series, QString name_x, QString name_y, int x_trans=c_AXE_TRANS_LIN, int y_trans=c_AXE_TRANS_LIN, bool dots_visible=false, bool man_axis_style_x=false, bool man_axis_style_y=false, double man_min_x=0, double man_max_x=1, double man_min_y=0, double man_max_y=1, int ticks_x=AXE_TICK_COUNT_MAJOR_DEFAULT, int ticks_y=AXE_TICK_COUNT_MAJOR_DEFAULT)
Definition: d_plot.cpp:3432
void connect_Zoom(D_Viewer *viewer)
Definition: d_viewer.cpp:128
D_MAKRO_IonTracks(D_Storage *pStorage, QWidget *parent=0)
Definition: d_makro_iontracks.cpp:12
const QStringList QSL_StatList
Definition: d_enum.h:797
@ c_STAT_NUMBER_OF_STATS
Definition: d_enum.h:795
static int Reduce_Geometric(Mat *pMA_Out, Mat *pMA_In, int geometric, int connectivity=8, int thickness=1, uchar value=255)
Definition: d_img_proc.cpp:16215
QString Save_Image()
D_Viewer::Save_Image Saves the image at FI_LastSaved.
Definition: d_viewer.cpp:2157
static int Math_ImgImg_BitAnd(Mat *pMA_Out, Mat *pMA_In1, Mat *pMA_In2)
Definition: d_img_proc.cpp:13187
static int Merge(Mat *pMA_Out, Mat *pMA_In0, Mat *pMA_In1, Mat *pMA_In2, Mat *pMA_In3, unsigned int channels, bool channel_use[4])
Definition: d_img_proc.cpp:4060
const int BORDER_DEFAULT
Definition: d_opencv_typedefs.h:78
QString Save_Table_Dialog()
Definition: d_table.cpp:158
void set_dir_M_IonTracks(QString path)
Definition: d_storage.h:107
Mat * get_Adress(size_t pos)
Definition: d_storage.h:54
static int Filter_Gauss(Mat *pMA_Out, Mat *pMA_In, int size_x, int size_y, int border, double sigma_x, double sigma_y)
Definition: d_img_proc.cpp:9083
static int Calc_Stats(vector< double > *v_stats, vector< double > v_data, bool calc_sorted)
Definition: d_stat.cpp:16
~D_MAKRO_IonTracks()
Definition: d_makro_iontracks.cpp:104
@ c_FEAT_AREA
Definition: d_enum.h:1347
@ c_STAT_MEAN_ARITMETIC
Definition: d_enum.h:740
@ ER_index_out_of_range
Definition: d_enum.h:146