ForceBalance API  1.3
Automated optimization of force fields and empirical potentials
Classes | Functions | Variables
src.nifty Namespace Reference

Classes

class  LineChunker
 
class  RawFileHandler
 Exactly like FileHandler, except no newline character is printed at the end of each message. More...
 
class  RawStreamHandler
 Exactly like StreamHandler, except no newline character is printed at the end of each message. More...
 

Functions

def pvec1d (vec1d, precision=1, format="e", loglevel=INFO)
 Printout of a 1-D vector. More...
 
def astr (vec1d, precision=4)
 Write an array to a string so we can use it to key a dictionary. More...
 
def pmat2d (mat2d, precision=1, format="e", loglevel=INFO)
 Printout of a 2-D array. More...
 
def grouper (iterable, n)
 Collect data into fixed-length chunks or blocks. More...
 
def encode (l)
 
def segments (e)
 
def commadash (l)
 
def uncommadash (s)
 
def natural_sort (l)
 Return a natural sorted list. More...
 
def printcool (text, sym="#", bold=False, color=2, ansi=None, bottom='-', minwidth=50, center=True, sym2="=")
 Cool-looking printout for slick formatting of output. More...
 
def printcool_dictionary (Dict, title="Dictionary Keys : Values", bold=False, color=2, keywidth=25, topwidth=50, center=True, leftpad=0)
 See documentation for printcool; this is a nice way to print out keys/values in a dictionary. More...
 
def isint (word)
 ONLY matches integers! If you have a decimal point? None shall pass! More...
 
def isfloat (word)
 Matches ANY number; it can be a decimal, scientific notation, what have you CAUTION - this will also match an integer. More...
 
def isdecimal (word)
 Matches things with a decimal only; see isint and isfloat. More...
 
def floatornan (word)
 Returns a big number if we encounter NaN. More...
 
def col (vec)
 Given any list, array, or matrix, return a 1-column 2D array. More...
 
def row (vec)
 Given any list, array, or matrix, return a 1-row 2D array. More...
 
def flat (vec)
 Given any list, array, or matrix, return a single-index array. More...
 
def est124 (val)
 Given any positive floating point value, return a value [124]e+xx that is closest to it in the log space. More...
 
def est1234568 (val)
 Given any positive floating point value, return a value [1234568]e+xx that is closest to it in the log space. More...
 
def monotonic (arr, start, end)
 
def monotonic_decreasing (arr, start=None, end=None, verbose=False)
 Return the indices of an array corresponding to strictly monotonic decreasing behavior. More...
 
def orthogonalize (vec1, vec2)
 Given two vectors vec1 and vec2, project out the component of vec1 that is along the vec2-direction. More...
 
def invert_svd (X, thresh=1e-12)
 Invert a matrix using singular value decomposition. More...
 
def get_least_squares (x, y, w=None, thresh=1e-12)
 
def statisticalInefficiency (A_n, B_n=None, fast=False, mintime=3, warn=True)
 Compute the (cross) statistical inefficiency of (two) timeseries. More...
 
def mean_stderr (ts)
 Return mean and standard deviation of a time series ts. More...
 
def multiD_statisticalInefficiency (A_n, B_n=None, fast=False, mintime=3, warn=True)
 
def lp_dump (obj, fnm, protocol=0)
 Write an object to a zipped pickle file specified by the path. More...
 
def lp_load (fnm)
 Read an object from a bzipped file specified by the path. More...
 
def getWorkQueue ()
 
def getWQIds ()
 
def createWorkQueue (wq_port, debug=True, name=package)
 
def destroyWorkQueue ()
 
def queue_up (wq, command, input_files, output_files, tag=None, tgt=None, verbose=True, print_time=60)
 Submit a job to the Work Queue. More...
 
def queue_up_src_dest (wq, command, input_files, output_files, tag=None, tgt=None, verbose=True, print_time=60)
 Submit a job to the Work Queue. More...
 
def wq_wait1 (wq, wait_time=10, wait_intvl=1, print_time=60, verbose=False)
 This function waits ten seconds to see if a task in the Work Queue has finished. More...
 
def wq_wait (wq, wait_time=10, wait_intvl=10, print_time=60, verbose=False)
 This function waits until the work queue is completely empty. More...
 
def click ()
 Stopwatch function for timing. More...
 
def splitall (path)
 
def bak (path, dest=None, cwd=None, start=1)
 
def onefile (fnm=None, ext=None, err=False)
 
def listfiles (fnms=None, ext=None, err=False, dnm=None)
 
def extract_tar (tarfnm, fnms, force=False)
 Extract a list of files from .tar archive with any compression. More...
 
def GoInto (Dir)
 
def allsplit (Dir)
 
def Leave (Dir)
 
def MissingFileInspection (fnm)
 
def wopen (dest, binary=False)
 If trying to write to a symbolic link, remove it first. More...
 
def LinkFile (src, dest, nosrcok=False)
 
def CopyFile (src, dest)
 
def link_dir_contents (abssrcdir, absdestdir)
 
def remove_if_exists (fnm)
 Remove the file if it exists (doesn't return an error). More...
 
def which (fnm)
 
def copy_tree_over (src, dest)
 Copy a source directory tree to a destination directory tree, overwriting files as necessary. More...
 
def warn_press_key (warning, timeout=10)
 
def warn_once (warning, warnhash=None)
 Prints a warning but will only do so once in a given run. More...
 
def concurrent_map (func, data)
 Similar to the bultin function map(). More...
 

Variables

string package = "ForceBalance"
 
 logger = getLogger(__name__)
 
 handler = RawStreamHandler()
 
bool HaveBZ2 = True
 
bool HaveGZ = True
 
 rootdir = os.path.dirname(os.path.abspath(__file__))
 
float kb = 0.008314462618
 Boltzmann constant in kJ mol^-1 k^-1. More...
 
float kb_si = 1.380649e-23
 
float bohr2ang = 0.529177210903
 
float ang2bohr = 1.0 / bohr2ang
 
float au2kcal = 627.5094740630558
 
float kcal2au = 1.0 / au2kcal
 
float au2kj = 2625.4996394798254
 
float kj2au = 1.0 / au2kj
 
float grad_au2gmx = 49614.75258920567
 
float grad_gmx2au = 1.0 / grad_au2gmx
 
float au2evang = 51.422067476325886
 
float evang2au = 1.0 / au2evang
 
int c_lightspeed = 299792458.
 
float hbar = 1.054571817e-34
 
float avogadro = 6.02214076e23
 
float au_mass = 9.1093837015e-31
 
float amu_mass = 1.66053906660e-27
 
float amu2au = amu_mass / au_mass
 
int cm2au = 100 * c_lightspeed * (2*np.pi*hbar) * avogadro / 1000 / au2kj
 
float ambervel2au = 9.349961132249932e-04
 
float eqcgmx = au2kj
 Q-Chem to GMX unit conversion for energy. More...
 
float fqcgmx = -grad_au2gmx
 Q-Chem to GMX unit conversion for force. More...
 
 WORK_QUEUE = None
 
 WQIDS = defaultdict(list)
 
list specific_lst
 
 specific_dct = dict(list(itertools.chain(*[[(j,i[1]) for j in i[0]] for i in specific_lst])))
 

Function Documentation

◆ allsplit()

def src.nifty.allsplit (   Dir)

Definition at line 1264 of file nifty.py.

◆ astr()

def src.nifty.astr (   vec1d,
  precision = 4 
)

Write an array to a string so we can use it to key a dictionary.

Definition at line 207 of file nifty.py.

◆ bak()

def src.nifty.bak (   path,
  dest = None,
  cwd = None,
  start = 1 
)

Definition at line 1087 of file nifty.py.

◆ click()

def src.nifty.click ( )

Stopwatch function for timing.

Definition at line 1065 of file nifty.py.

◆ col()

def src.nifty.col (   vec)

Given any list, array, or matrix, return a 1-column 2D array.

Input: vec = The input vector that is to be made into a column

Output: A 1-column 2D array

Definition at line 448 of file nifty.py.

◆ commadash()

def src.nifty.commadash (   l)

Definition at line 239 of file nifty.py.

Here is the call graph for this function:

◆ concurrent_map()

def src.nifty.concurrent_map (   func,
  data 
)

Similar to the bultin function map().

But spawn a thread for each argument and apply func concurrently.

Note: unlike map(), we cannot take an iterable argument. data should be an indexable sequence.

Definition at line 1635 of file nifty.py.

◆ copy_tree_over()

def src.nifty.copy_tree_over (   src,
  dest 
)

Copy a source directory tree to a destination directory tree, overwriting files as necessary.

This does not require removing the destination folder, which can reduce the number of times shutil.rmtree needs to be called.

Definition at line 1376 of file nifty.py.

◆ CopyFile()

def src.nifty.CopyFile (   src,
  dest 
)

Definition at line 1333 of file nifty.py.

Here is the call graph for this function:

◆ createWorkQueue()

def src.nifty.createWorkQueue (   wq_port,
  debug = True,
  name = package 
)

Definition at line 912 of file nifty.py.

◆ destroyWorkQueue()

def src.nifty.destroyWorkQueue ( )

Definition at line 926 of file nifty.py.

◆ encode()

def src.nifty.encode (   l)

Definition at line 230 of file nifty.py.

◆ est1234568()

def src.nifty.est1234568 (   val)

Given any positive floating point value, return a value [1234568]e+xx that is closest to it in the log space.

Just because I don't like seven and nine. Call me a numberist?

Definition at line 497 of file nifty.py.

◆ est124()

def src.nifty.est124 (   val)

Given any positive floating point value, return a value [124]e+xx that is closest to it in the log space.

Definition at line 474 of file nifty.py.

◆ extract_tar()

def src.nifty.extract_tar (   tarfnm,
  fnms,
  force = False 
)

Extract a list of files from .tar archive with any compression.

The file is extracted to the base folder of the archive.

Parameters

tarfnm : Name of the archive file. fnms : str or list File names to be extracted. force : bool, optional If true, then force extraction of file even if they already exist on disk.

Definition at line 1235 of file nifty.py.

◆ flat()

def src.nifty.flat (   vec)

Given any list, array, or matrix, return a single-index array.

Parameters
[in]vecThe data to be flattened
Returns
answer The flattened data

Definition at line 467 of file nifty.py.

◆ floatornan()

def src.nifty.floatornan (   word)

Returns a big number if we encounter NaN.

Parameters
[in]wordThe string to be converted
Returns
answer The string converted to a float; if not a float, return 1e10
Todo:
I could use suggestions for making this better.

Definition at line 430 of file nifty.py.

Here is the call graph for this function:

◆ get_least_squares()

def src.nifty.get_least_squares (   x,
  y,
  w = None,
  thresh = 1e-12 
)
__ __
| |
| 1 (x0) (x0)^2 (x0)^3 |
| 1 (x1) (x1)^2 (x1)^3 |
| 1 (x2) (x2)^2 (x2)^3 |
| 1 (x3) (x3)^2 (x3)^3 |
| 1 (x4) (x4)^2 (x4)^3 |
|__ __|
Parameters
[in]X(2-D array) An array of X-values (see above)
[in]Y(array) An array of Y-values (only used in getting the least squares coefficients)
[in]w(array) An array of weights, hopefully normalized to one.
[out]BetaThe least-squares coefficients
[out]HatThe hat matrix that takes linear combinations of data y-values to give fitted y-values (weights)
[out]yfitThe fitted y-values
[out]MPPIThe Moore-Penrose pseudoinverse (multiply by Y to get least-squares coefficients, multiply by dY/dk to get derivatives of least-squares coefficients)

Definition at line 662 of file nifty.py.

Here is the call graph for this function:

◆ getWorkQueue()

def src.nifty.getWorkQueue ( )

Definition at line 904 of file nifty.py.

◆ getWQIds()

def src.nifty.getWQIds ( )

Definition at line 908 of file nifty.py.

◆ GoInto()

def src.nifty.GoInto (   Dir)

Definition at line 1254 of file nifty.py.

◆ grouper()

def src.nifty.grouper (   iterable,
  n 
)

Collect data into fixed-length chunks or blocks.

Definition at line 224 of file nifty.py.

◆ invert_svd()

def src.nifty.invert_svd (   X,
  thresh = 1e-12 
)

Invert a matrix using singular value decomposition.

Parameters
[in]XThe 2-D NumPy array containing the matrix to be inverted
[in]threshThe SVD threshold; eigenvalues below this are not inverted but set to zero
Returns
Xt The 2-D NumPy array containing the inverted matrix

Definition at line 621 of file nifty.py.

◆ isdecimal()

def src.nifty.isdecimal (   word)

Matches things with a decimal only; see isint and isfloat.

Parameters
[in]wordString (for instance, '123', '153.0', '2.', '-354')
Returns
answer Boolean which specifies whether the string is a number with a decimal point

Definition at line 418 of file nifty.py.

Here is the call graph for this function:

◆ isfloat()

def src.nifty.isfloat (   word)

Matches ANY number; it can be a decimal, scientific notation, what have you CAUTION - this will also match an integer.

Parameters
[in]wordString (for instance, '123', '153.0', '2.', '-354')
Returns
answer Boolean which specifies whether the string is any number

Definition at line 405 of file nifty.py.

◆ isint()

def src.nifty.isint (   word)

ONLY matches integers! If you have a decimal point? None shall pass!

Parameters
[in]wordString (for instance, '123', '153.0', '2.', '-354')
Returns
answer Boolean which specifies whether the string is an integer (only +/- sign followed by digits)

Definition at line 390 of file nifty.py.

◆ Leave()

def src.nifty.Leave (   Dir)

Definition at line 1270 of file nifty.py.

Here is the call graph for this function:

◆ link_dir_contents()

def src.nifty.link_dir_contents (   abssrcdir,
  absdestdir 
)

Definition at line 1345 of file nifty.py.

◆ LinkFile()

def src.nifty.LinkFile (   src,
  dest,
  nosrcok = False 
)

Definition at line 1313 of file nifty.py.

Here is the call graph for this function:

◆ listfiles()

def src.nifty.listfiles (   fnms = None,
  ext = None,
  err = False,
  dnm = None 
)

Definition at line 1173 of file nifty.py.

◆ lp_dump()

def src.nifty.lp_dump (   obj,
  fnm,
  protocol = 0 
)

Write an object to a zipped pickle file specified by the path.

Definition at line 817 of file nifty.py.

◆ lp_load()

def src.nifty.lp_load (   fnm)

Read an object from a bzipped file specified by the path.

Definition at line 836 of file nifty.py.

◆ mean_stderr()

def src.nifty.mean_stderr (   ts)

Return mean and standard deviation of a time series ts.

Definition at line 795 of file nifty.py.

Here is the call graph for this function:

◆ MissingFileInspection()

def src.nifty.MissingFileInspection (   fnm)

Definition at line 1292 of file nifty.py.

◆ monotonic()

def src.nifty.monotonic (   arr,
  start,
  end 
)

Definition at line 527 of file nifty.py.

◆ monotonic_decreasing()

def src.nifty.monotonic_decreasing (   arr,
  start = None,
  end = None,
  verbose = False 
)

Return the indices of an array corresponding to strictly monotonic decreasing behavior.

Parameters

arr : numpy.ndarray Input array start : int Starting index (first element if None) end : int Ending index (last element if None)

Returns

indices : numpy.ndarray Selected indices

Definition at line 567 of file nifty.py.

◆ multiD_statisticalInefficiency()

def src.nifty.multiD_statisticalInefficiency (   A_n,
  B_n = None,
  fast = False,
  mintime = 3,
  warn = True 
)

Definition at line 800 of file nifty.py.

Here is the call graph for this function:

◆ natural_sort()

def src.nifty.natural_sort (   l)

Return a natural sorted list.

Definition at line 285 of file nifty.py.

◆ onefile()

def src.nifty.onefile (   fnm = None,
  ext = None,
  err = False 
)

Definition at line 1119 of file nifty.py.

Here is the call graph for this function:

◆ orthogonalize()

def src.nifty.orthogonalize (   vec1,
  vec2 
)

Given two vectors vec1 and vec2, project out the component of vec1 that is along the vec2-direction.

Parameters
[in]vec1The projectee (i.e. output is some modified version of vec1)
[in]vec2The projector (component subtracted out from vec1 is parallel to this)
Returns
answer A copy of vec1 but with the vec2-component projected out.

Definition at line 608 of file nifty.py.

◆ pmat2d()

def src.nifty.pmat2d (   mat2d,
  precision = 1,
  format = "e",
  loglevel = INFO 
)

Printout of a 2-D array.

Parameters
[in]mat2da 2-D array

Definition at line 215 of file nifty.py.

◆ printcool()

def src.nifty.printcool (   text,
  sym = "#",
  bold = False,
  color = 2,
  ansi = None,
  bottom = '-',
  minwidth = 50,
  center = True,
  sym2 = "=" 
)

Cool-looking printout for slick formatting of output.

Parameters
[in]textThe string that the printout is based upon. This function will print out the string, ANSI-colored and enclosed in the symbol for example:
#################
### I am cool ###
#################
[in]symThe surrounding symbol
[in]boldWhether to use bold print
[in]colorThe ANSI color:
1 red
2 green
3 yellow
4 blue
5 magenta
6 cyan
7 white
[in]bottomThe symbol for the bottom bar
[in]minwidthThe minimum width for the box, if the text is very short then we insert the appropriate number of padding spaces
Returns
bar The bottom bar is returned for the user to print later, e.g. to mark off a 'section'

Definition at line 321 of file nifty.py.

Here is the call graph for this function:

◆ printcool_dictionary()

def src.nifty.printcool_dictionary (   Dict,
  title = "Dictionary Keys : Values",
  bold = False,
  color = 2,
  keywidth = 25,
  topwidth = 50,
  center = True,
  leftpad = 0 
)

See documentation for printcool; this is a nice way to print out keys/values in a dictionary.

The keys in the dictionary are sorted before printing out.

Parameters
[in]dictThe dictionary to be printed
[in]titleThe title of the printout

Definition at line 366 of file nifty.py.

Here is the call graph for this function:

◆ pvec1d()

def src.nifty.pvec1d (   vec1d,
  precision = 1,
  format = "e",
  loglevel = INFO 
)

Printout of a 1-D vector.

Parameters
[in]vec1da 1-D vector

Definition at line 199 of file nifty.py.

◆ queue_up()

def src.nifty.queue_up (   wq,
  command,
  input_files,
  output_files,
  tag = None,
  tgt = None,
  verbose = True,
  print_time = 60 
)

Submit a job to the Work Queue.

Parameters
[in]wq(Work Queue Object)
[in]command(string) The command to run on the remote worker.
[in]input_files(list of files) A list of locations of the input files.
[in]output_files(list of files) A list of locations of the output files.

Definition at line 941 of file nifty.py.

◆ queue_up_src_dest()

def src.nifty.queue_up_src_dest (   wq,
  command,
  input_files,
  output_files,
  tag = None,
  tgt = None,
  verbose = True,
  print_time = 60 
)

Submit a job to the Work Queue.

This function is a bit fancier in that we can explicitly specify where the input files come from, and where the output files go to.

Parameters
[in]wq(Work Queue Object)
[in]command(string) The command to run on the remote worker.
[in]input_files(list of 2-tuples) A list of local and remote locations of the input files.
[in]output_files(list of 2-tuples) A list of local and remote locations of the output files.

Definition at line 974 of file nifty.py.

◆ remove_if_exists()

def src.nifty.remove_if_exists (   fnm)

Remove the file if it exists (doesn't return an error).

Definition at line 1358 of file nifty.py.

◆ row()

def src.nifty.row (   vec)

Given any list, array, or matrix, return a 1-row 2D array.

Parameters
[in]vecThe input vector that is to be made into a row
Returns
answer A 1-row 2D array

Definition at line 458 of file nifty.py.

◆ segments()

def src.nifty.segments (   e)

Definition at line 233 of file nifty.py.

◆ splitall()

def src.nifty.splitall (   path)

Definition at line 1071 of file nifty.py.

◆ statisticalInefficiency()

def src.nifty.statisticalInefficiency (   A_n,
  B_n = None,
  fast = False,
  mintime = 3,
  warn = True 
)

Compute the (cross) statistical inefficiency of (two) timeseries.

Notes The same timeseries can be used for both A_n and B_n to get the autocorrelation statistical inefficiency. The fast method described in Ref [1] is used to compute g.

References [1] J. D. Chodera, W. C. Swope, J. W. Pitera, C. Seok, and K. A. Dill. Use of the weighted histogram analysis method for the analysis of simulated and parallel tempering simulations. JCTC 3(1):26-41, 2007.

Examples

Compute statistical inefficiency of timeseries data with known correlation time.

import timeseries A_n = timeseries.generateCorrelatedTimeseries(N=100000, tau=5.0) g = statisticalInefficiency(A_n, fast=True)

 @param[in] A_n (required, numpy array) - A_n[n] is nth value of
 timeseries A.  Length is deduced from vector.

 @param[in] B_n (optional, numpy array) - B_n[n] is nth value of
 timeseries B.  Length is deduced from vector.  If supplied, the
 cross-correlation of timeseries A and B will be estimated instead of
 the autocorrelation of timeseries A.

 @param[in] fast (optional, boolean) - if True, will use faster (but
 less accurate) method to estimate correlation time, described in
 Ref. [1] (default: False)

 @param[in] mintime (optional, int) - minimum amount of correlation
 function to compute (default: 3) The algorithm terminates after
 computing the correlation time out to mintime when the correlation
 function furst goes negative.  Note that this time may need to be
 increased if there is a strong initial negative peak in the
 correlation function.

 @return g The estimated statistical inefficiency (equal to 1 + 2
 tau, where tau is the correlation time).  We enforce g >= 1.0.

Definition at line 740 of file nifty.py.

◆ uncommadash()

def src.nifty.uncommadash (   s)

Definition at line 249 of file nifty.py.

◆ warn_once()

def src.nifty.warn_once (   warning,
  warnhash = None 
)

Prints a warning but will only do so once in a given run.

Definition at line 1611 of file nifty.py.

◆ warn_press_key()

def src.nifty.warn_press_key (   warning,
  timeout = 10 
)

Definition at line 1599 of file nifty.py.

◆ which()

def src.nifty.which (   fnm)

Definition at line 1362 of file nifty.py.

◆ wopen()

def src.nifty.wopen (   dest,
  binary = False 
)

If trying to write to a symbolic link, remove it first.

Definition at line 1304 of file nifty.py.

◆ wq_wait()

def src.nifty.wq_wait (   wq,
  wait_time = 10,
  wait_intvl = 10,
  print_time = 60,
  verbose = False 
)

This function waits until the work queue is completely empty.

Definition at line 1056 of file nifty.py.

Here is the call graph for this function:

◆ wq_wait1()

def src.nifty.wq_wait1 (   wq,
  wait_time = 10,
  wait_intvl = 1,
  print_time = 60,
  verbose = False 
)

This function waits ten seconds to see if a task in the Work Queue has finished.

Definition at line 996 of file nifty.py.

Variable Documentation

◆ ambervel2au

float src.nifty.ambervel2au = 9.349961132249932e-04

Definition at line 155 of file nifty.py.

◆ amu2au

float src.nifty.amu2au = amu_mass / au_mass

Definition at line 153 of file nifty.py.

◆ amu_mass

float src.nifty.amu_mass = 1.66053906660e-27

Definition at line 152 of file nifty.py.

◆ ang2bohr

float src.nifty.ang2bohr = 1.0 / bohr2ang

Definition at line 139 of file nifty.py.

◆ au2evang

float src.nifty.au2evang = 51.422067476325886

Definition at line 146 of file nifty.py.

◆ au2kcal

float src.nifty.au2kcal = 627.5094740630558

Definition at line 140 of file nifty.py.

◆ au2kj

float src.nifty.au2kj = 2625.4996394798254

Definition at line 142 of file nifty.py.

◆ au_mass

float src.nifty.au_mass = 9.1093837015e-31

Definition at line 151 of file nifty.py.

◆ avogadro

float src.nifty.avogadro = 6.02214076e23

Definition at line 150 of file nifty.py.

◆ bohr2ang

float src.nifty.bohr2ang = 0.529177210903

Definition at line 138 of file nifty.py.

◆ c_lightspeed

int src.nifty.c_lightspeed = 299792458.

Definition at line 148 of file nifty.py.

◆ cm2au

int src.nifty.cm2au = 100 * c_lightspeed * (2*np.pi*hbar) * avogadro / 1000 / au2kj

Definition at line 154 of file nifty.py.

◆ eqcgmx

float src.nifty.eqcgmx = au2kj

Q-Chem to GMX unit conversion for energy.

Definition at line 159 of file nifty.py.

◆ evang2au

float src.nifty.evang2au = 1.0 / au2evang

Definition at line 147 of file nifty.py.

◆ fqcgmx

float src.nifty.fqcgmx = -grad_au2gmx

Q-Chem to GMX unit conversion for force.

Definition at line 161 of file nifty.py.

◆ grad_au2gmx

float src.nifty.grad_au2gmx = 49614.75258920567

Definition at line 144 of file nifty.py.

◆ grad_gmx2au

float src.nifty.grad_gmx2au = 1.0 / grad_au2gmx

Definition at line 145 of file nifty.py.

◆ handler

src.nifty.handler = RawStreamHandler()

Definition at line 98 of file nifty.py.

◆ HaveBZ2

bool src.nifty.HaveBZ2 = True

Definition at line 107 of file nifty.py.

◆ HaveGZ

bool src.nifty.HaveGZ = True

Definition at line 114 of file nifty.py.

◆ hbar

float src.nifty.hbar = 1.054571817e-34

Definition at line 149 of file nifty.py.

◆ kb

float src.nifty.kb = 0.008314462618

Boltzmann constant in kJ mol^-1 k^-1.

Definition at line 134 of file nifty.py.

◆ kb_si

float src.nifty.kb_si = 1.380649e-23

Definition at line 135 of file nifty.py.

◆ kcal2au

float src.nifty.kcal2au = 1.0 / au2kcal

Definition at line 141 of file nifty.py.

◆ kj2au

float src.nifty.kj2au = 1.0 / au2kj

Definition at line 143 of file nifty.py.

◆ logger

src.nifty.logger = getLogger(__name__)

Definition at line 92 of file nifty.py.

◆ package

string src.nifty.package = "ForceBalance"

Definition at line 54 of file nifty.py.

◆ rootdir

src.nifty.rootdir = os.path.dirname(os.path.abspath(__file__))

Definition at line 120 of file nifty.py.

◆ specific_dct

src.nifty.specific_dct = dict(list(itertools.chain(*[[(j,i[1]) for j in i[0]] for i in specific_lst])))

Definition at line 1290 of file nifty.py.

◆ specific_lst

list src.nifty.specific_lst
Initial value:
1 = [(['mdrun','grompp','trjconv','g_energy','g_traj'], "Make sure to install GROMACS and add it to your path (or set the gmxpath option)"),
2  (['force.mdin', 'stage.leap'], "This file is needed for setting up AMBER force matching targets"),
3  (['conf.pdb', 'mono.pdb'], "This file is needed for setting up OpenMM condensed phase property targets"),
4  (['liquid.xyz', 'liquid.key', 'mono.xyz', 'mono.key'], "This file is needed for setting up OpenMM condensed phase property targets"),
5  (['dynamic', 'analyze', 'minimize', 'testgrad', 'vibrate', 'optimize', 'polarize', 'superpose'], "Make sure to install TINKER and add it to your path (or set the tinkerpath option)"),
6  (['runcuda.sh', 'npt.py', 'npt_tinker.py'], "This file belongs in the ForceBalance source directory, not sure why it is missing"),
7  (['input.xyz'], "This file is needed for TINKER molecular property targets"),
8  (['.*key$', '.*xyz$'], "I am guessing this file is probably needed by TINKER"),
9  (['.*gro$', '.*top$', '.*itp$', '.*mdp$', '.*ndx$'], "I am guessing this file is probably needed by GROMACS")
10  ]

Definition at line 1278 of file nifty.py.

◆ WORK_QUEUE

src.nifty.WORK_QUEUE = None

Definition at line 899 of file nifty.py.

◆ WQIDS

src.nifty.WQIDS = defaultdict(list)

Definition at line 902 of file nifty.py.