Openholo  v4.2
Open Source Digital Holographic Library
ophSigCH.h
Go to the documentation of this file.
1 #pragma once
2 
3 
4 #ifndef __ophSigCH_h
5 #define __ophSigCH_h
6 
7 #include "ophSig.h"
8 
12 
31 
38 class SIG_DLL ophSigCH : public ophSig
39 {
40 public:
44  explicit ophSigCH(void);
45 
46  bool setCHparam(vector<Real> &z, int maxIter, double tau, double tolA, int tvIter);
47  bool runCH(int complexHidx);
48  bool saveNumRec(const char *fname);
49  bool readConfig(const char * fname);
50  bool loadCHtemp(const char *real, const char *imag, uint8_t bitpixel);
51 
52  matrix<Complex<Real>> propagationHoloAS(matrix<Complex<Real>> complexH, float depth);
53 
54 
55 protected:
56 
57  virtual ~ophSigCH(void) = default;
58  void tvdenoise(matrix<Real> &input, double lam, int iters, matrix<Real> &output);
59  double tvnorm(matrix<Real> &input);
60  void c2ri(matrix<Complex<Real>> &complexinput, matrix<Real> &realimagoutput);
61  void ri2c(matrix<Real> &realimaginput, matrix<Complex<Real>> &complexoutput);
62  void volume2plane(matrix<Real>& realimagvolumeinput, vector<Real> z, matrix<Real>& realimagplaneoutput);
63  void plane2volume(matrix<Real>& realimagplaneinput, vector<Real> z, matrix<Real>& realimagplaneoutput);
64  void convert3Dto2D(matrix<Complex<Real>> *complex3Dinput, int nz, matrix<Complex<Real>> &complex2Doutput);
65  void convert2Dto3D(matrix<Complex<Real>> &complex2Dinput, int nz, matrix<Complex<Real>> *complex3Doutput);
66  void twist(matrix<Real>& realimagplaneinput, matrix<Real>& realimagvolumeoutput);
67  double matrixEleSquareSum(matrix<Real> &input);
68 
69 
70 
71 public:
72 
73 
74 
75 protected:
76  int Nz;
77  int MaxIter;
78  double Tau;
79  double TolA;
80  int TvIter;
81  matrix<Real> NumRecRealImag;
82  vector<Real> Z;
83 
84 };
85 
86 #endif // !__ophSigCH_h
vector< Real > Z
Definition: ophSigCH.h:82
int MaxIter
Definition: ophSigCH.h:77
double TolA
Definition: ophSigCH.h:79
bool readConfig(const char *fname)
Function for Read parameter.
Definition: ophSig.cpp:1265
int TvIter
Definition: ophSigCH.h:80
Definition: ophSig.h:478
#define SIG_DLL
Definition: ophSig.h:64
int Nz
Definition: ophSigCH.h:76
matrix< Real > NumRecRealImag
Definition: ophSigCH.h:81
double Tau
Definition: ophSigCH.h:78