Skip to content

Commit

Permalink
Merge for 2.14.0 release
Browse files Browse the repository at this point in the history
  • Loading branch information
benmwebb committed Nov 20, 2020
2 parents d5f3a95 + fb05ebc commit 369679c
Show file tree
Hide file tree
Showing 218 changed files with 10,131 additions and 957 deletions.
7 changes: 7 additions & 0 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,11 @@ if(POLICY CMP0094)
cmake_policy(SET CMP0094 NEW)
endif(POLICY CMP0094)

# Use new-style variables/escapes
if(POLICY CMP0053)
cmake_policy(SET CMP0053 NEW)
endif(POLICY CMP0053)

include(${CMAKE_SOURCE_DIR}/modules/rmf/dependency/RMF/cmake_modules/IMPFindPython.cmake)
imp_find_python()

Expand Down Expand Up @@ -409,11 +414,13 @@ if(IMP_DOXYGEN_FOUND)
COMMAND ${IMP_DOXYGEN_EXECUTABLE} doxygen/ref.html
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/build/doxygen_show_warnings.py --warn=${CMAKE_BINARY_DIR}/doxygen/ref-warnings.txt
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/build/doxygen_fix_links.py ${CMAKE_BINARY_DIR}/doc/ref
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/build/doxygen_fix_php.py ${CMAKE_BINARY_DIR}/doc/ref
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/build/doxygen_add_ref_nav.py ${CMAKE_SOURCE_DIR}
# Rebuild manual so that it can link to the refguide tags
COMMAND ${IMP_DOXYGEN_EXECUTABLE} doxygen/manual.html
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/build/doxygen_show_warnings.py --warn=${CMAKE_BINARY_DIR}/doxygen/manual-warnings.txt
COMMAND patch -p1 < ${CMAKE_SOURCE_DIR}/doc/doxygen/search.patch
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/build/doxygen_fix_php.py ${CMAKE_BINARY_DIR}/doc/manual
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/build/doxygen_add_nav.py ${CMAKE_SOURCE_DIR} . doc/manual tools
COMMAND ${PYTHON_EXECUTABLE} ${CMAKE_SOURCE_DIR}/tools/build/doxygen_spell_check.py doxygen/manual/xml ${CMAKE_SOURCE_DIR}/doc/standards_exceptions
WORKING_DIRECTORY ${CMAKE_BINARY_DIR}
Expand Down
15 changes: 15 additions & 0 deletions ChangeLog.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,21 @@
ChangeLog {#changelog}
=========

# 2.14.0 - 2020-12-02 # {#changelog_2_14_0}
- All IMP.parallel worker classes are now subclasses of IMP.parallel.Worker;
the old class names still exist as aliases, but are deprecated.
- The IMP.kinematics module has had a major overhaul.
- The Windows .exe installer now supports Python 3.9, and has dropped support
for Python 3.5.
- New applications of IMP are now available:
- [Integrative structures of the Nef-CD4-AP2 complex](https://salilab.org/Nef_CD4_AP2/)
- [Integrative Modeling of Yeast Exocyst Complex](https://salilab.org/exocyst/)
- [Integrative threading of protein structure using secondary structure elements](https://salilab.org/SSEThread/)
- Bugfix: fix near-infinite loop in FoXS JavaScript output when no models
are fit.
- Bugfix: IMP.saxs.Restraint should now work correctly when some or all
particles are members of rigid bodies.

# 2.13.0 - 2020-05-14 # {#changelog_2_13_0}
- Ubuntu .deb packages now use Python 3 by default (install the imp-python2
package if you want to use Python 2) and support MPI (install the
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2.13.0
2.14.0
2 changes: 1 addition & 1 deletion doc/manual/cmake_config.md
Original file line number Diff line number Diff line change
Expand Up @@ -84,7 +84,7 @@ For example, on a Mac with Homebrew, where `python` is Homebrew's
`/usr/local/bin/python`, old versions of CMake will often find Apple's Python
headers. This can be resolved (if you cannot upgrade CMake to 3.14 or later)
by telling CMake where the Homebrew Python headers and library
are, by addinng to your CMake invocation something like
are, by adding to your CMake invocation something like
`-DPYTHON_LIBRARY=/usr/local/opt/python@2/Frameworks/Python.framework/Versions/Current/lib/libpython2.7.dylib -DPYTHON_INCLUDE_DIR=/usr/local/opt/python@2/Frameworks/Python.framework/Versions/Current/Headers`

## CMake reports that it found a dependency but then reports failed {#cmake_compile}
Expand Down
6 changes: 3 additions & 3 deletions doc/manual/kinematics_rrt.dox
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ First, obtain the input files used in this example and put them in the
current directory, by typing:

\code{.sh}
cp <imp_example_path>/kinematics/antibody/* .
cp "<imp_example_path>"/kinematics/antibody/*.* .
\endcode

(On a Windows machine, use `copy` rather than `cp`.) Here, `<imp_example_path>`
Expand All @@ -33,8 +33,8 @@ print(IMP.kinematics.get_example_path('antibody'))</tt>'.
\section kinematics_rrt_calc Calculation

The structure of the antibody is available in the
\external{http://www.pdb.org,RCSB Protein Data Bank (PDB)} as code
\external{http://www.pdb.org/pdb/explore/explore.do?structureId=1IGT,1igt}
\external{https://www.rcsb.org/,RCSB Protein Data Bank (PDB)} as code
\external{https://www.rcsb.org/structure/1IGT,1igt}
(file <tt>1igt.pdb</tt>). The atomic structure can be sampled by running <tt>rrt_sample</tt>. First, we need to define the linker regions (residues 229-235 in chains B and D). These residues are listed in the input file <tt>linker.txt</tt>. Since the antibody contains four chains (A-D), we would like to connect them into a single rigid body using '-c' connect_chains option. We do that for the antibody structure using the S-S bonds between the chains. Therefore, the file <tt>conect_chains.txt</tt> specifies atom numbers for the two chains we want to connect.

\code{.sh}
Expand Down
2 changes: 1 addition & 1 deletion doc/manual/outoftree.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ Building modules out of tree {#outoftree}
Normally to build an %IMP module it is placed in the `modules` subdirectory
together with the rest of the %IMP source code and then all of %IMP is
built, as per the [installation instructions](@ref installation_source).
However, this makes builing a module an expensive process (as the build
However, this makes building a module an expensive process (as the build
system needs to check whether any part of %IMP has changed, not just the
module itself) and it is awkward to build a module against multiple
versions of %IMP, for example against both the latest stable release and
Expand Down
2 changes: 1 addition & 1 deletion doc/manual/rmf.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ atom::Hierarchy data is stored as RMF::REPRESENTATION nodes in the file.

There is exactly one node in the RMF file per IMP::Particle in the hierarchy.
The link classes are implemented in terms of a bunch of helper classes,
each of whichs handle a particular type of data.
each of which handles a particular type of data.

The main tricky part is handling rigid bodies. In particular, the particles
defining the rigid body are not always part of the %IMP hierarchy, and
Expand Down
2 changes: 1 addition & 1 deletion modules/EMageFit/doc/scripts.dox
Original file line number Diff line number Diff line change
Expand Up @@ -99,7 +99,7 @@ called from DominoModel.
IMP.em2d.sampling - Sets the positions and orientations for the components of
the assembly before combining them using DOMINO. In the EMageFit benchmark the
set of Monte Carlo solutions was used as input to DOMINO, but
any other combination of positions and orientations for the the subunits
any other combination of positions and orientations for the subunits
could be used.

IMP.em2d.solutions_io - Contains the class <tt>ResultsDB</tt> for managing
Expand Down
2 changes: 1 addition & 1 deletion modules/EMageFit/pyext/src/imp_general/alignments.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
def get_reference_frames_from_chain_alignment(reference_rbs, reference_index,
rbs_to_align, index_to_align):
"""
Align the rigid bodies rbs_to_align to the the reference frames of
Align the rigid bodies rbs_to_align to the reference frames of
reference_rbs. The rb with index_to_align is aligned to the reference rb
with reference_index. The function returns the reference frames to
apply to the rbs_to_align.
Expand Down
4 changes: 2 additions & 2 deletions modules/EMageFit/pyext/src/solutions_io.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ def gather_best_solution_results(fns, fn_output, max_number=50000,
raising an error. This option is to tolerate some files
of the databases being broken because the cluster fails,
fill the disks, etc
@param orderby Criterion used to sort the the records
@param orderby Criterion used to sort the records
NOTE:
Makes sure to reorder all column names if necessary before merging
The record for the native solution is only added once (from first file).
Expand Down Expand Up @@ -588,7 +588,7 @@ def get_native_rank(self, orderby):

def get_nth_largest_cluster(self, position, table_name="clusters"):
"""
Recover the the information about the n-th largest cluster
Recover the information about the n-th largest cluster
@param position Cluster position (by size) requested
(1 is the largest cluster)
@param table_name Table where the information about the
Expand Down
2 changes: 1 addition & 1 deletion modules/algebra/test/test_inverse.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ def setUp(self):
self.v2 = IMP.algebra.Vector3D(-41.472, 8.922, -63.657)

def test_inverse(self):
"""Check that the the inverse of a transformation works"""
"""Check that the inverse of a transformation works"""
rt = IMP.algebra.get_rotation_from_fixed_xyz(0.2, 0.8, -0.4)
t = IMP.algebra.Transformation3D(
rt, IMP.algebra.Vector3D(20.0, -12.4, 18.6))
Expand Down
2 changes: 1 addition & 1 deletion modules/algebra/test/test_sphere_cover.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ def test_get_uniform_surface_cover(self):
delta=4 * radius / numpts ** .5)

def test_get_uniform_surface_cover_not_on_000(self):
"""Check uniform cover when the the center is not on (0,0,0)"""
"""Check uniform cover when the center is not on (0,0,0)"""
# IMP.random_number_generator.seed(1)
center = IMP.algebra.Vector3D(4.0, 5.0, -9.0)
radius = 5.0
Expand Down
19 changes: 15 additions & 4 deletions modules/atom/include/CHARMMParameters.h
Original file line number Diff line number Diff line change
Expand Up @@ -227,19 +227,30 @@ class IMPATOMEXPORT CHARMMParameters : public ForceFieldParameters {
CHARMMDihedralParametersList param;
internal::CHARMMDihedralNames types =
internal::CHARMMDihedralNames(type1, type2, type3, type4);
// Get the first match, using wildcards
// Look for matches without wildcards
DihedralParameters::const_iterator match = find_dihedral(
dihedral_parameters_.begin(), dihedral_parameters_.end(), types, true);
dihedral_parameters_.begin(), dihedral_parameters_.end(), types, false);
if (match != dihedral_parameters_.end()) {
// If it matched, look for duplicate dihedral terms (this time the
// match must be exactly the same as the first match)
param.push_back(match->second);
while ((match = find_dihedral(match + 1, dihedral_parameters_.end(),
match->first, false)) !=
dihedral_parameters_.end()) {
param.push_back(match->second);
}
} else {
// If no matches, try again with wildcards
match = find_dihedral(
dihedral_parameters_.begin(), dihedral_parameters_.end(), types, true);
if (match != dihedral_parameters_.end()) {
param.push_back(match->second);
while ((match = find_dihedral(match + 1, dihedral_parameters_.end(),
match->first, true)) !=
dihedral_parameters_.end()) {
param.push_back(match->second);
}
}
}

if (param.size() == 0) {
IMP_THROW("No CHARMM parameters found for dihedral "
<< type1 << "-" << type2 << "-" << type3 << "-" << type4,
Expand Down
2 changes: 1 addition & 1 deletion modules/atom/include/DihedralSingletonScore.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ IMPATOM_BEGIN_NAMESPACE
//! Score the dihedral angle.
/** This scores the dihedral using information stored in its Dihedral
decorator. The form of the score is \f[
\frac{1}{2} s|s| (1.0 + \cos(\chi m - \chi_i))
\frac{1}{2} s|s| + s^2\cos(\chi m + \chi_i))
\f] where \f$s\f$ is the stiffness, \f$m\f$ the multiplicity, \f$\chi_i\f$
the ideal value of the dihedral, and \f$\chi\f$ the actual value.
Expand Down
2 changes: 1 addition & 1 deletion modules/atom/include/ImproperSingletonScore.h
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ IMPATOM_BEGIN_NAMESPACE
as the angle between the plane in which the first three atoms lie and
the plane in which the last three atoms lie.
\note The multiplicity of the the Dihedral is not used.
\note The multiplicity of the Dihedral is not used.
\see CHARMMTopology::add_impropers(), Dihedral.
*/
Expand Down
60 changes: 60 additions & 0 deletions modules/atom/include/LoopStatisticalPairScore.h
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
/**
* \file IMP/atom/LoopStatisticalPairScore.h
* \brief Fiser/Melo loop modeling statistical potential
*
* Copyright 2007-2020 IMP Inventors. All rights reserved.
*
*/

#ifndef IMPATOM_LOOP_STATISTICAL_PAIR_SCORE_H
#define IMPATOM_LOOP_STATISTICAL_PAIR_SCORE_H

#include <IMP/atom/atom_config.h>
#include "Hierarchy.h"
#include <IMP/score_functor/LoopStatistical.h>
#include <IMP/score_functor/DistancePairScore.h>
#include <IMP/core/StatisticalPairScore.h>

IMPATOM_BEGIN_NAMESPACE

/** \name Fiser/Melo loop modeling statistical potential
\imp provides the Fiser/Melo loop modeling statistical potential.
\note These are quite large objects as they store the whole
lookup table. It is much better to share them between
restraints than to create separate instances.
*/
class LoopStatisticalPairScore;
typedef score_functor::LoopStatisticalType LoopStatisticalType;

//! Score atoms based on the Fiser/Melo loop modeling statistical potential
/**
See Fiser et al, Modeling of loops in protein structures.
Protein Science 9, 1753-1773, 2000.
Like DOPE, this potential should not be applied to two atoms from
the same residue. You may need to use the SameResiduePairFilter
to filter these out.
*/
class LoopStatisticalPairScore
: public score_functor::DistancePairScore<score_functor::LoopStatistical> {
typedef score_functor::DistancePairScore<score_functor::LoopStatistical> P;

public:
LoopStatisticalPairScore(
double threshold = std::numeric_limits<double>::max())
: P(score_functor::LoopStatistical(threshold)) {}
LoopStatisticalPairScore(double threshold, TextInput data_file)
: P(score_functor::LoopStatistical(threshold, data_file)) {}
};

/** Add the Fiser/Melo loop modeling atom types to the atoms in the hierarchy.
*/
IMPATOMEXPORT void add_loop_statistical_score_data(atom::Hierarchy h);

/** @} */
IMPATOM_END_NAMESPACE

#endif /* IMPATOM_LOOP_STATISTICAL_PAIR_SCORE_H */
57 changes: 16 additions & 41 deletions modules/atom/include/MolecularDynamics.h
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,16 @@ IMPATOM_BEGIN_NAMESPACE
class IMPATOMEXPORT LinearVelocity : public Decorator {
static void do_setup_particle(Model *m, ParticleIndex pi,
const algebra::Vector3D v = algebra::Vector3D(0, 0, 0)) {
m->add_attribute(get_velocity_key(0), pi, v[0]);
m->add_attribute(get_velocity_key(1), pi, v[1]);
m->add_attribute(get_velocity_key(2), pi, v[2]);
m->add_attribute(get_velocities_key(), pi, v.get_coordinates());
}

public:
static FloatKey get_velocity_key(unsigned int i) {
IMP_USAGE_CHECK(i < 3, "Out of range coordinate");
static const FloatKey keys[] = {FloatKey("vx"), FloatKey("vy"),
FloatKey("vz")};
return keys[i];
static FloatsKey get_velocities_key() {
static const FloatsKey key("linvel");
return key;
}

public:
static bool get_is_setup(Model *m, ParticleIndex pi) {
return m->get_has_attribute(get_velocity_key(0), pi)
&& m->get_has_attribute(get_velocity_key(1), pi)
&& m->get_has_attribute(get_velocity_key(2), pi);
return m->get_has_attribute(get_velocities_key(), pi);
}

IMP_DECORATOR_METHODS(LinearVelocity, Decorator);
Expand All @@ -49,17 +42,13 @@ class IMPATOMEXPORT LinearVelocity : public Decorator {
void set_velocity(const algebra::Vector3D &v) {
Model *m = get_model();
ParticleIndex pi = get_particle_index();
m->set_attribute(get_velocity_key(0), pi, v[0]);
m->set_attribute(get_velocity_key(1), pi, v[1]);
m->set_attribute(get_velocity_key(2), pi, v[2]);
m->set_attribute(get_velocities_key(), pi, v.get_coordinates());
}

algebra::Vector3D get_velocity() const {
Model *m = get_model();
ParticleIndex pi = get_particle_index();
return algebra::Vector3D(m->get_attribute(get_velocity_key(0), pi),
m->get_attribute(get_velocity_key(1), pi),
m->get_attribute(get_velocity_key(2), pi));
return algebra::Vector3D(m->get_attribute(get_velocities_key(), pi));
}
};

Expand All @@ -71,25 +60,17 @@ class IMPATOMEXPORT LinearVelocity : public Decorator {
class IMPATOMEXPORT AngularVelocity : public Decorator {
static void do_setup_particle(Model *m, ParticleIndex pi,
const algebra::Vector4D v = algebra::Vector4D(0, 0, 0, 0)) {
m->add_attribute(get_velocity_key(0), pi, v[0]);
m->add_attribute(get_velocity_key(1), pi, v[1]);
m->add_attribute(get_velocity_key(2), pi, v[2]);
m->add_attribute(get_velocity_key(3), pi, v[3]);
m->add_attribute(get_velocities_key(), pi, v.get_coordinates());
}
static FloatsKey get_velocities_key() {
static const FloatsKey key("angvel");
return key;
}

public:
static FloatKey get_velocity_key(unsigned int i) {
IMP_USAGE_CHECK(i < 4, "Out of range coordinate");
static const FloatKey keys[] = {FloatKey("angvel0"), FloatKey("angvel1"),
FloatKey("angvel2"), FloatKey("angvel3")};
return keys[i];
}

static bool get_is_setup(Model *m, ParticleIndex pi) {
return m->get_has_attribute(get_velocity_key(0), pi)
&& m->get_has_attribute(get_velocity_key(1), pi)
&& m->get_has_attribute(get_velocity_key(2), pi)
&& m->get_has_attribute(get_velocity_key(3), pi);
return m->get_has_attribute(get_velocities_key(), pi);
}

IMP_DECORATOR_METHODS(AngularVelocity, Decorator);
Expand All @@ -99,19 +80,13 @@ class IMPATOMEXPORT AngularVelocity : public Decorator {
void set_velocity(const algebra::Vector4D &v) {
Model *m = get_model();
ParticleIndex pi = get_particle_index();
m->set_attribute(get_velocity_key(0), pi, v[0]);
m->set_attribute(get_velocity_key(1), pi, v[1]);
m->set_attribute(get_velocity_key(2), pi, v[2]);
m->set_attribute(get_velocity_key(3), pi, v[3]);
m->set_attribute(get_velocities_key(), pi, v.get_coordinates());
}

algebra::Vector4D get_velocity() const {
Model *m = get_model();
ParticleIndex pi = get_particle_index();
return algebra::Vector4D(m->get_attribute(get_velocity_key(0), pi),
m->get_attribute(get_velocity_key(1), pi),
m->get_attribute(get_velocity_key(2), pi),
m->get_attribute(get_velocity_key(3), pi));
return algebra::Vector4D(m->get_attribute(get_velocities_key(), pi));
}
};

Expand Down
8 changes: 7 additions & 1 deletion modules/atom/include/Representation.h
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ enum RepresentationType {
class IMPATOMEXPORT Representation : public Hierarchy {
static IntsKey get_types_key();
static ParticleIndexesKey get_representations_key();
static FloatKey get_resolution_key(unsigned int index);
static FloatsKey get_resolutions_key();
static FloatKey get_base_resolution_key();

static void do_setup_particle(Model *m, ParticleIndex pi,
Expand Down Expand Up @@ -81,6 +81,12 @@ class IMPATOMEXPORT Representation : public Hierarchy {
//! Get all resolutions that are available for a specific RepresentationType.
Floats get_resolutions(RepresentationType type = BALLS) const;

//! Remove the given representation.
/** The representation is only removed from the Representation
decorator; it is not destroyed. For that, use IMP::atom::destroy().
*/
void remove_representation(ParticleIndexAdaptor rep);

//! If you've changed the parent, update all the resolutions
void update_parents();
};
Expand Down
Loading

0 comments on commit 369679c

Please sign in to comment.