ProSHADE  0.7.6.6 (JUL 2022)
Protein Shape Detection
ProSHADE.hpp
Go to the documentation of this file.
1 
25 //==================================================== ProSHADE library code
26 #include "ProSHADE_tasks.hpp"
27 
28 //==================================================== Overinclusion protection
29 #ifndef PROSHADE
30 #define PROSHADE
31 
39 {
40 private:
41  //================================================ General variables
42  proshade_unsign noStructures;
43  proshade_signed verbose;
44 
45  //================================================ Variables regarding distances computation
46  std::vector < proshade_double > enLevs;
47  std::vector < proshade_double > trSigm;
48  std::vector < proshade_double > rotFun;
49 
50  //================================================ Variables regarding re-boxing task
51  std::vector < proshade_signed* > originalBounds;
52  std::vector < proshade_signed* > reboxedBounds;
53  std::vector < proshade_double* > manipulatedMaps;
54 
55  //================================================ Variables regarding overlay optimisation
56  std::vector < proshade_double > eulerAngles;
57  std::vector < proshade_double > coordRotationCentre;
58  std::vector < proshade_double > overlayTranslation;
59 
60  //================================================ Variables regarding symmetry detection
61  std::string symRecommType;
62  proshade_unsign symRecommFold;
63  std::vector< proshade_double* > RecomSymAxes;
64  std::vector < std::vector< proshade_double > > allCSymAxes;
65  std::vector< proshade_double > mapCOMShift;
66 
67 private:
68  //================================================ Mutator functions
69  void setRecommendedSymmetry ( std::string val );
70  void setRecommendedFold ( proshade_unsign val );
71  void setRecommendedAxis ( proshade_double* sym );
72 
73 public:
74  //================================================ Constructors / Destructors
75 #if defined ( _WIN64 ) || defined ( _WIN32 )
76  __declspec(dllexport) ProSHADE_run ( ProSHADE_settings* settings );
77  __declspec(dllexport) ~ProSHADE_run ( void );
78 #else
79  ProSHADE_run ( ProSHADE_settings* settings );
80  ~ProSHADE_run ( void );
81 #endif
82 
83 public:
84  //================================================ General accessor functions
85  proshade_unsign getNoStructures ( void );
86  proshade_signed getVerbose ( void );
87 
88  //================================================ Symmetry accessor functions
89  proshade_unsign getNoRecommendedSymmetryAxes ( void );
90  proshade_unsign getNoSymmetryAxes ( void );
91 
92 public:
93  //================================================ Distances results accessor functions
94 #if defined ( _WIN64 ) || defined ( _WIN32 )
95  std::vector< proshade_double > __declspec(dllexport) getEnergyLevelsVector ( void );
96  std::vector< proshade_double > __declspec(dllexport) getTraceSigmaVector ( void );
97  std::vector< proshade_double > __declspec(dllexport) getRotationFunctionVector ( void );
98 #else
99  std::vector< proshade_double > getEnergyLevelsVector ( void );
100  std::vector< proshade_double > getTraceSigmaVector ( void );
101  std::vector< proshade_double > getRotationFunctionVector ( void );
102 #endif
103 
104  //================================================ Symmetry results accessor functions
105 #if defined ( _WIN64 ) || defined ( _WIN32 )
106  std::string __declspec(dllexport) getSymmetryType ( void );
107  proshade_unsign __declspec(dllexport) getSymmetryFold ( void );
108  std::vector< std::string > __declspec(dllexport) getSymmetryAxis ( proshade_unsign axisNo );
109  std::vector < std::vector< proshade_double > > __declspec(dllexport) getAllCSyms ( void );
110  std::vector < proshade_double > __declspec(dllexport) getMapCOMProcessChange ( void );
111 #else
112  std::string getSymmetryType ( void );
113  proshade_unsign getSymmetryFold ( void );
114  std::vector< std::string > getSymmetryAxis ( proshade_unsign axisNo );
115  std::vector < std::vector< proshade_double > > getAllCSyms ( void );
116  std::vector < proshade_double > getMapCOMProcessChange ( void );
117 #endif
118 
119  //================================================ Re-boxing results accessor functions
120 #if defined ( _WIN64 ) || defined ( _WIN32 )
121  std::vector< proshade_signed > __declspec(dllexport) getOriginalBounds ( proshade_unsign strNo );
122  std::vector< proshade_signed > __declspec(dllexport) getReBoxedBounds ( proshade_unsign strNo );
123  proshade_double __declspec(dllexport) getMapValue ( proshade_unsign strNo, proshade_unsign mapIndex );
124 #else
125  std::vector< proshade_signed > getOriginalBounds ( proshade_unsign strNo );
126  std::vector< proshade_signed > getReBoxedBounds ( proshade_unsign strNo );
127  proshade_double getMapValue ( proshade_unsign strNo, proshade_unsign mapIndex );
128 #endif
129 
130  //================================================ Overlay results accessor functions
131 #if defined ( _WIN64 ) || defined ( _WIN32 )
132  std::vector< proshade_double > __declspec(dllexport) getEulerAngles ( void );
133  std::vector< proshade_double > __declspec(dllexport) getOptimalRotMat ( void );
134  std::vector< proshade_double > __declspec(dllexport) getTranslationToOrigin ( void );
135  std::vector< proshade_double > __declspec(dllexport) getOriginToOverlayTranslation ( void );
136 #else
137  std::vector< proshade_double > getEulerAngles ( void );
138  std::vector< proshade_double > getOptimalRotMat ( void );
139  std::vector< proshade_double > getTranslationToOrigin ( void );
140  std::vector< proshade_double > getOriginToOverlayTranslation ( void );
141 #endif
142 
143 };
144 
145 //==================================================== These functions should be in ProSHADE_run class, but I cannot make them work with Numpy from there, so they are here.
146 #if defined ( _WIN64 ) || defined ( _WIN32 )
147  void __declspec(dllexport) getReBoxedMap ( ProSHADE_run* run, proshade_unsign strNo, double *reboxMap, int len );
148 #else
149  void getReBoxedMap ( ProSHADE_run* run, proshade_unsign strNo, double *reboxMap, int len );
150 #endif
151 
152 #endif
ProSHADE_run::~ProSHADE_run
~ProSHADE_run(void)
Destructor for the ProSHADE class.
Definition: ProSHADE.cpp:1998
ProSHADE_run::getRotationFunctionVector
std::vector< proshade_double > getRotationFunctionVector(void)
This function returns the full rotation function distances vector from the first to all other structu...
Definition: ProSHADE.cpp:3044
ProSHADE_run::getAllCSyms
std::vector< std::vector< proshade_double > > getAllCSyms(void)
This function returns a all symmetry axes as a vector of vectors of doubles.
Definition: ProSHADE.cpp:3154
ProSHADE_run::getNoSymmetryAxes
proshade_unsign getNoSymmetryAxes(void)
This function returns the number of detected recommended symmetry axes.
Definition: ProSHADE.cpp:3075
ProSHADE_run::getEulerAngles
std::vector< proshade_double > getEulerAngles(void)
This function returns the vector of Euler angles with best overlay correlation.
Definition: ProSHADE.cpp:3295
ProSHADE_run::getVerbose
proshade_signed getVerbose(void)
This function returns the verbose value.
Definition: ProSHADE.cpp:3065
getReBoxedMap
void getReBoxedMap(ProSHADE_run *run, proshade_unsign strNo, double *reboxMap, int len)
This function returns the re-boxed structure map 1D array for the processed structure.
Definition: ProSHADE.cpp:3267
ProSHADE_run::getSymmetryAxis
std::vector< std::string > getSymmetryAxis(proshade_unsign axisNo)
This function returns a single symmetry axis as a vector of strings from the recommended symmetry axe...
Definition: ProSHADE.cpp:3099
ProSHADE_run
This class provides the access point to the library.
Definition: ProSHADE.hpp:39
ProSHADE_run::getSymmetryFold
proshade_unsign getSymmetryFold(void)
This is the main accessor function for the user to get to know what symmetry fold ProSHADE has detect...
Definition: ProSHADE.cpp:2047
ProSHADE_run::getTranslationToOrigin
std::vector< proshade_double > getTranslationToOrigin(void)
This function returns the negative values of the position of the rotation centre (the point about whi...
Definition: ProSHADE.cpp:3351
ProSHADE_settings
This class stores all the settings and is passed to the executive classes instead of a multitude of p...
Definition: ProSHADE_settings.hpp:37
ProSHADE_run::getSymmetryType
std::string getSymmetryType(void)
This is the main accessor function for the user to get to know what symmetry type ProSHADE has detect...
Definition: ProSHADE.cpp:2032
ProSHADE_run::getEnergyLevelsVector
std::vector< proshade_double > getEnergyLevelsVector(void)
This function returns the energy level distances vector from the first to all other structures.
Definition: ProSHADE.cpp:3016
ProSHADE_run::getReBoxedBounds
std::vector< proshade_signed > getReBoxedBounds(proshade_unsign strNo)
This function returns a specific structure re-boxed bounds.
Definition: ProSHADE.cpp:3216
ProSHADE_run::ProSHADE_run
ProSHADE_run(ProSHADE_settings *settings)
Contructor for the ProSHADE_run class.
Definition: ProSHADE.cpp:1900
ProSHADE_run::getMapValue
proshade_double getMapValue(proshade_unsign strNo, proshade_unsign mapIndex)
This function returns a single, specific structure map value.
Definition: ProSHADE.cpp:3250
ProSHADE_run::getNoRecommendedSymmetryAxes
proshade_unsign getNoRecommendedSymmetryAxes(void)
This function returns the number of detected recommended symmetry axes.
Definition: ProSHADE.cpp:3085
ProSHADE_tasks.hpp
This header declares all the taks functions.
ProSHADE_run::getOptimalRotMat
std::vector< proshade_double > getOptimalRotMat(void)
This function returns the vector forming rotation matrix (rows first) with best overlay correlation.
Definition: ProSHADE.cpp:3317
ProSHADE_run::getOriginalBounds
std::vector< proshade_signed > getOriginalBounds(proshade_unsign strNo)
This function returns a specific structure original bounds.
Definition: ProSHADE.cpp:3184
ProSHADE_run::getTraceSigmaVector
std::vector< proshade_double > getTraceSigmaVector(void)
This function returns the trace sigma distances vector from the first to all other structures.
Definition: ProSHADE.cpp:3030
ProSHADE_run::getNoStructures
proshade_unsign getNoStructures(void)
This function returns the number of structures used.
Definition: ProSHADE.cpp:3055
ProSHADE_run::getMapCOMProcessChange
std::vector< proshade_double > getMapCOMProcessChange(void)
This function returns the internal map COM shift.
Definition: ProSHADE.cpp:3169
ProSHADE_run::getOriginToOverlayTranslation
std::vector< proshade_double > getOriginToOverlayTranslation(void)
This function returns the translation required to move the structure from origin to optimal overlay.
Definition: ProSHADE.cpp:3379