Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
34 commits
Select commit Hold shift + click to select a range
6906a08
Fleshed out ScoreFunctionGeneric a bit.
brownbp1 Jul 5, 2022
d789fec
In the middle of replacing the hard-coded mutates with serializable m…
brownbp1 Jul 5, 2022
6ab9aa3
Merged workstation branch into local.
brownbp1 Jul 6, 2022
189dee9
First version of the FLD refactor complete. Compiles, but not tested …
brownbp1 Jul 7, 2022
f268d65
Accidentally kept the same alias for the new FragmentMutateInterface …
brownbp1 Jul 7, 2022
1231df0
Changed default in ScoreFunctionGeneric from Mean to Index.
brownbp1 Jul 7, 2022
a8e2c7f
Similarly changed constructor defaults in ScoreFunctionGeneric. Chang…
brownbp1 Jul 7, 2022
bbf49a1
Fixed a null pointer issue that I made during initialization of the M…
brownbp1 Jul 7, 2022
1b46094
Swapping to get best instead of get last. Also added final metrics to…
brownbp1 Jul 7, 2022
8474369
Working on a long overdue refactor of the druglikeness filter in Frag…
brownbp1 Jul 7, 2022
55ebc62
Forgot a few classes where MapConformer was instantiated.
brownbp1 Jul 7, 2022
bebf798
Missed some
brownbp1 Jul 7, 2022
b84a940
Deprecated app, but whatever
brownbp1 Jul 7, 2022
4c05c3e
Changed default in FragmentMutateInterface
brownbp1 Jul 7, 2022
de3d388
Trying something in Alchemy serialization
brownbp1 Jul 7, 2022
81296a4
Nope
brownbp1 Jul 7, 2022
64a4c70
hmm
brownbp1 Jul 7, 2022
66a9b08
nevermind
brownbp1 Jul 7, 2022
18743b7
Adding another FragmentSplitInterface-derived class to make it easier…
brownbp1 Jul 7, 2022
5125ebe
Headers and other stuff
brownbp1 Jul 7, 2022
f39e75d
Added back a function that is pure virtual. Oops. Ran cleaner.
brownbp1 Jul 7, 2022
3456b2b
added empty default
brownbp1 Jul 7, 2022
82e6175
fixed atom index parsing
brownbp1 Jul 7, 2022
8e5d1ce
typo in RISH
brownbp1 Jul 7, 2022
548b5eb
Include bonded hydrogen atoms (if desired) in new split
brownbp1 Jul 7, 2022
3ac2ff9
minor
brownbp1 Jul 7, 2022
32d27dd
make indices mutable
brownbp1 Jul 7, 2022
8bc6b87
bug fix; minor feature add
brownbp1 Jul 7, 2022
a8c56e4
Working on a bug fix for MoleculeFit
brownbp1 Jul 9, 2022
4759f0f
Need to convert from FragmentEnsemble to FragmentComplete to get the …
brownbp1 Jul 9, 2022
ac15244
Fixed bug in MoleculeFit during MolAlign RMSDX assignment. Minor feat…
brownbp1 Jul 10, 2022
8d53f8e
Moving some functionality to the base class of FragmentMutateInterfac…
brownbp1 Jul 11, 2022
ec30422
Finished updating the FragmentMutateInterface-derived class options. …
brownbp1 Jul 15, 2022
8b83f9d
Noted a bug in FragmentAlchemy and applied a small patch. Should be r…
brownbp1 Jul 21, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions apps/internal/chemistry/bcl_app_link_fragments.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -258,7 +258,7 @@ namespace bcl
command::Parameter
(
"type", "the type of druglikenes to use",
command::ParameterCheckAllowed( storage::Vector< std::string>::Create( "IsConstitutionDruglike", "IsConstitutionDruglikeAndHitlike", "None")),
command::ParameterCheckAllowed( storage::Vector< std::string>::Create( "IsConstitutionDruglike", "IsConstitutionDruglikeAndHitlike", "Constant(1.0)")),
"IsConstitutionDruglike"
)
)
Expand Down Expand Up @@ -1526,7 +1526,7 @@ namespace bcl
(
cleaner.Clean
(
new_frag_v, REFERENCE, m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue()
new_frag_v, REFERENCE, descriptor::CheminfoProperty( m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue())
)
);
return clean_frag;
Expand Down Expand Up @@ -1561,7 +1561,7 @@ namespace bcl
);
static chemistry::FragmentMapConformer conf_mapper
(
m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue(),
descriptor::CheminfoProperty( m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue()),
m_MDLString,
m_PocketFilename,
SCORER,
Expand Down
49 changes: 41 additions & 8 deletions apps/internal/chemistry/bcl_app_molecule_mutate.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -13,22 +13,24 @@
// (c)

// initialize the static initialization fiasco finder, if macro ENABLE_FIASCO_FINDER is defined
#include "command/bcl_command_parameter_check_ranged.h"
#include "util/bcl_util_static_initialization_fiasco_finder.h"
BCL_StaticInitializationFiascoFinder

// include header of this class
#include "app/bcl_app_apps.h"
#include "internal/chemistry/bcl_app_molecule_mutate.h"

// include bcl headers
#include "chemistry/bcl_chemistry_fragment_feed.h"
#include "chemistry/bcl_chemistry_fragment_mutate_interface.h"
#include "command/bcl_command_app_default_flags.h"
#include "command/bcl_command_flag_dynamic.h"
#include "command/bcl_command_flag_static.h"
#include "command/bcl_command_parameter_check_ranged.h"
#include "command/bcl_command_parameter_check_serializable.h"
#include "internal/chemistry/bcl_app_molecule_mutate.h"
#include "io/bcl_io_file.h"
#include "math/bcl_math_mutate_interface.h"
#include "storage/bcl_storage_template_instantiations.h"

namespace bcl
{
namespace app
Expand Down Expand Up @@ -83,7 +85,20 @@ namespace bcl
new command::FlagStatic
(
"accumulate",
"accumulate mutations into one molecule; be careful"
"accumulate mutations at specified 'mutable_atoms' into one molecule; "
"only applicable if using the application-level 'mutable_atoms'; "
"similar behavior can be achieved using multiple implementations sequentially "
"with careful mutate-level atom selections."
)
),
m_FinalProductOnlyFlag
(
new command::FlagStatic
(
"final_product_only",
"only return the product resulting from all mutates; by default a "
"molecule is returned after each mutation; this flag is useful if you "
"are only interested in the final product."
)
),
m_RecenterFlag
Expand Down Expand Up @@ -115,6 +130,7 @@ namespace bcl
MoleculeMutate::MoleculeMutate( const MoleculeMutate &PARENT) :
m_ImplementationFlag( PARENT.m_ImplementationFlag),
m_AccumulateFlag( PARENT.m_AccumulateFlag),
m_FinalProductOnlyFlag( PARENT.m_FinalProductOnlyFlag),
m_MutableAtomsFlag( PARENT.m_MutableAtomsFlag),
m_RecenterFlag( PARENT.m_RecenterFlag),
m_OutputFilenameFlag( PARENT.m_OutputFilenameFlag),
Expand Down Expand Up @@ -173,6 +189,9 @@ namespace bcl
//! make all mutations to one molecule
sp_cmd->AddFlag( m_AccumulateFlag);

//! only return the last molecule after all mutations have been applied
sp_cmd->AddFlag( m_FinalProductOnlyFlag);

//! whether to recenter the molecules
sp_cmd->AddFlag( m_RecenterFlag);

Expand Down Expand Up @@ -295,8 +314,15 @@ namespace bcl
current_frag = *( mutated_object.GetArgument());
continue;
}
chemistry::FragmentComplete fragment( *( mutated_object.GetArgument()));
Write( fragment);
if
(
!m_FinalProductOnlyFlag->GetFlag() ||
i+1 == n_mutates
)
{
chemistry::FragmentComplete fragment( *( mutated_object.GetArgument()));
Write( fragment);
}
}
}
}
Expand All @@ -322,8 +348,15 @@ namespace bcl
if( mutated_object.GetArgument().IsDefined())
{
current_frag = *( mutated_object.GetArgument());
chemistry::FragmentComplete fragment( *( mutated_object.GetArgument()));
Write( fragment);
if
(
!m_FinalProductOnlyFlag->GetFlag() ||
i+1 == n_mutates
)
{
chemistry::FragmentComplete fragment( *( mutated_object.GetArgument()));
Write( fragment);
}
}
}
}
Expand Down
3 changes: 3 additions & 0 deletions apps/internal/chemistry/bcl_app_molecule_mutate.h
Original file line number Diff line number Diff line change
Expand Up @@ -68,6 +68,9 @@ namespace bcl
//! accumulate all mutations onto a single molecule
util::ShPtr< command::FlagInterface> m_AccumulateFlag;

//! only return the last molecule after all mutations have been applied
util::ShPtr< command::FlagInterface> m_FinalProductOnlyFlag;

//! whether to recenter the molecules
util::ShPtr< command::FlagInterface> m_RecenterFlag;

Expand Down
14 changes: 7 additions & 7 deletions apps/internal/chemistry/bcl_app_reaction_combichem.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,7 @@ namespace bcl
command::Parameter
(
"type", "the type of druglikenes to use",
command::ParameterCheckAllowed( storage::Vector< std::string>::Create( "IsConstitutionDruglike", "IsConstitutionDruglikeAndHitlike", "None")),
command::ParameterCheckAllowed( storage::Vector< std::string>::Create( "IsConstitutionDruglike", "IsConstitutionDruglikeAndHitlike", "Constant(1.0)")),
"IsConstitutionDruglike"
)
)
Expand Down Expand Up @@ -641,7 +641,7 @@ namespace bcl
chemistry::HydrogensHandler::Remove( atoms);
chemistry::FragmentMapConformer cleaner
(
m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue(),
descriptor::CheminfoProperty( m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue()),
m_CorinaFlag->GetFlag()
);
util::ShPtr< chemistry::FragmentComplete> clean_mol
Expand All @@ -650,7 +650,7 @@ namespace bcl
(
atoms,
*ens_itr,
m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue(),
descriptor::CheminfoProperty( m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue()),
false
)
);
Expand Down Expand Up @@ -765,17 +765,17 @@ namespace bcl
static chemistry::FragmentMapConformer cleaner;
if( m_CorinaFlag->GetFlag())
{
cleaner = chemistry::FragmentMapConformer( "None", true);
cleaner = chemistry::FragmentMapConformer( descriptor::CheminfoProperty( "Constant(1.0)"), true);
}
else
{
cleaner = chemistry::FragmentMapConformer( "None", false);
cleaner = chemistry::FragmentMapConformer( descriptor::CheminfoProperty( "Constant(1.0)"), false);
}
util::ShPtr< chemistry::FragmentComplete> clean_frag( cleaner.Clean
(
new_frag_v,
REFERENCE,
m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue()
descriptor::CheminfoProperty( m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue())
));
return clean_frag;
}
Expand Down Expand Up @@ -811,7 +811,7 @@ namespace bcl
);
static chemistry::FragmentMapConformer conf_mapper
(
m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue(),
descriptor::CheminfoProperty( m_DrugLikenessTypeFlag->GetFirstParameter()->GetValue()),
m_MDLString,
m_PocketFilename,
SCORER,
Expand Down
Loading