Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Python version of the following original work: | |
# Title: Sorting Real Schur Forms | |
# Author: Jan Brandts | |
# E-Mail: brandts-AT-science.uva.nl | |
# http://m2matlabdb.ma.tum.de/download.jsp?MC_ID=3&MP_ID=119 | |
# http://dx.doi.org/10.1002/nla.274 | |
# Institution: University of Amsterdam | |
# Description: In Matlab 6, there exists a command to generate a real Schur form, wheras another transforms a real | |
# Schur form into a complex one. There do not exist commands to prescribe the order in which the eigenvalues appear on | |
# the diagonal of the upper (quasi-) triangular factor T. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import numpy as np | |
import mdtraj | |
def tl(filename, chunk=100): | |
with mdtraj.open(filename, mode='r') as fh: | |
try: | |
return (len(fh) - 1) // chunk + 1 | |
except: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import scipy | |
import scipy.optimize | |
import warnings | |
__all__ = ['VAMP42'] | |
__author__ = 'Fabian Paul <fapa@uchicago.edu>' | |
def sigma(x): | |
return scipy.special.expit(x) |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pyparsing as pp | |
from pyparsing import pyparsing_common as ppc | |
__all__ = ['load_colvars', 'handle_colvars'] | |
pp.ParserElement.setDefaultWhitespaceChars(' \t') | |
vector = pp.Group(pp.Literal('(').suppress() + | |
pp.delimitedList(ppc.number, delim=',') + | |
pp.Literal(')').suppress()) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import mdtraj | |
import os | |
import os.path | |
import argparse | |
def prepare_maps(mut_pdb='mutant.pdb', wt_pdb=None): | |
if wt_pdb is None: | |
wt_pdb = os.path.expanduser('~/system/crystal.pdb') |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import rdkit.Chem | |
def reorder_atoms(mol_pdb_fname, template_pdb_fname, output_pdb_fname): | |
from rdkit.Chem import rdmolfiles | |
mol_to_transform = rdkit.Chem.rdmolfiles.MolFromPDBFile(mol_pdb_fname, removeHs=False) | |
transform_order = list(rdmolfiles.CanonicalRankAtoms(mol_to_transform)) | |
mol_template = rdkit.Chem.rdmolfiles.MolFromPDBFile(template_pdb_fname, removeHs=False) |
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
OlderNewer