Skip to content

Commit

Permalink
some cleaning
Browse files Browse the repository at this point in the history
  • Loading branch information
conradhuebler committed May 10, 2023
1 parent 440d29b commit 03cda41
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 10 deletions.
14 changes: 7 additions & 7 deletions src/capabilities/confscan.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -131,11 +131,11 @@ int ConfScanThreadNoReorder::execute()
m_input.dIb = Ib;
m_input.dIc = Ic;
#endif
m_diff_rotational = (Ia + Ib + Ic) * third;
m_DI = (Ia + Ib + Ic) * third;
const Matrix m = (m_reference.getPersisentImage() - m_target.getPersisentImage());
m_diff_ripser = m.cwiseAbs().sum();
m_DH = m.cwiseAbs().sum();
#ifdef WriteMoreInfo
m_input.dH = m_diff_ripser;
m_input.dH = m_DH;
m_input.dHM = m;
m_input.dE = std::abs(m_reference.Energy() - m_target.Energy()) * 2625.5;
#endif
Expand Down Expand Up @@ -683,12 +683,12 @@ void ConfScan::CheckRMSD()

for (auto* t : threads) {

m_dTI = std::max(m_dTI, t->DiffRot() * (t->RMSD() <= (m_sTI * m_rmsd_threshold)));
m_dTH = std::max(m_dTH, t->DiffRipser() * (t->RMSD() <= (m_sTH * m_rmsd_threshold)));
m_dTI = std::max(m_dTI, t->DI() * (t->RMSD() <= (m_sTI * m_rmsd_threshold)));
m_dTH = std::max(m_dTH, t->DH() * (t->RMSD() <= (m_sTH * m_rmsd_threshold)));
m_dTE = std::max(m_dTE, (std::abs(t->Reference()->Energy() - mol1->Energy()) * 2625.5) * (t->RMSD() <= (m_sTE * m_rmsd_threshold)));

m_dLI = std::max(m_dLI, t->DiffRot() * (t->RMSD() <= (m_sLI * m_rmsd_threshold)));
m_dLH = std::max(m_dLH, t->DiffRipser() * (t->RMSD() <= (m_sLH * m_rmsd_threshold)));
m_dLI = std::max(m_dLI, t->DI() * (t->RMSD() <= (m_sLI * m_rmsd_threshold)));
m_dLH = std::max(m_dLH, t->DH() * (t->RMSD() <= (m_sLH * m_rmsd_threshold)));
m_dLE = std::max(m_dLE, (std::abs(t->Reference()->Energy() - mol1->Energy()) * 2625.5) * (t->RMSD() <= (m_sLE * m_rmsd_threshold)));

if (t->KeepMolecule() == false) {
Expand Down
6 changes: 3 additions & 3 deletions src/capabilities/confscan.h
Original file line number Diff line number Diff line change
Expand Up @@ -192,8 +192,8 @@ class ConfScanThreadNoReorder : public CxxThread {
}

virtual int execute() override;
double DiffRot() const { return m_diff_rotational; }
double DiffRipser() const { return m_diff_ripser; }
double DI() const { return m_DI; }
double DH() const { return m_DH; }
double RMSD() const { return m_rmsd; }
const Molecule* Reference() const { return &m_reference; }

Expand Down Expand Up @@ -223,7 +223,7 @@ class ConfScanThreadNoReorder : public CxxThread {

private:
bool m_keep_molecule = true, m_break_pool = false;
double m_diff_rotational = 0, m_diff_ripser = 0;
double m_DI = 0, m_DH = 0;
Molecule m_reference, m_target;

RMSDDriver* m_driver;
Expand Down
3 changes: 3 additions & 0 deletions src/capabilities/curcumaopt.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -259,6 +259,9 @@ Molecule CurcumaOpt::LBFGSOptimise(const Molecule* initial, const json& controll
LBFGSParam<double> param;
param.epsilon = LBFGS_eps;
param.m = StoreIntermediate;
// param.max_linesearch = 10000;
// param.ftol = 1e-10;
// param.max_step = 10;
/*
param.linesearch = 3;
param.ftol = 1e-6;
Expand Down

0 comments on commit 03cda41

Please sign in to comment.