-
Notifications
You must be signed in to change notification settings - Fork 13
/
README
261 lines (180 loc) · 8.56 KB
/
README
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
The Molecular Modelling Toolkit
===============================
This is release 2.7 of MMTK, the Molecular Modelling Toolkit. For more
information about MMTK, look at the manual (in the directories
Doc/HTML and Doc/PDF) and at the examples in the directory Examples.
Please remember that MMTK, like Python, comes with neither a price tag
nor any warranty (see the file LICENSE for details). I use it for my
own work, and I consider it reasonably stable, but your mileage may
vary. If you find any problems with MMTK, please let me know, but
understand that I cannot promise extensive support (I am a scientist,
not a programmer, and much less a software distributor!). I also
gratefully accept additional example applications and other code
donations.
Installation
============
Note: the following are step-by-step instructions for installing
from source code. The only package manager that offers an
up-to-date version of MMTK is [Guix](https://guix.gnu.org/)
for Gnu/Linux. With Guix, installing MMTK is a matter of typing
```
guix install python2-mmtk
```
Otherwise, for Unix-like systems you may prefer to use the
[mmtk_install](https://github.com/roygroup/mmtk_install)
script for some automation, but be aware that it installs the
[path_integral branch](https://github.com/khinsen/MMTK/tree/path_integrals)
rather than the [master branch](https://github.com/khinsen/MMTK/tree/master),
which may not be what you want/need. You can change this in line 111
of the script.
Manual installation from source code
-------------------------------------
Prerequisites: Python 2.5 or higher, ScientificPython 2.6 or higher,
NumPy between 1.6 and 1.8.
MMTK is NOT compatible with NumPy 1.9 or later, because it relies on a
submodule of NumPy that was removed in version 1.9.
Note: MMTK is developed and tested using Python 2.7 and NumPy
1.8. However, it should work with Python 2.6 as well.
On most Unix systems, installation requires two commands:
python setup.py build
python setup.py install
The second command often requires root priviledges, as MMTK will be
installed in the Python library tree. There are many options for
building and installing, type
python setup.py build --help
or
python setup.py install --help
for details.
If you want MMTK's MPI support enabled, you must first install
ScientificPython with MPI support and then use mpipython instead of
python for running the compilation/installation procedure via
setup.py. Note that a version of MMTK compiled with MPI support
works only with the mpipython executable, not with an ordinary
python interpreter. However, there is no overhead for using
mpipython on a single processor.
Numeric vs NumPy
================
There are three nearly compatible implementations of numeric arrays for
Python: the original one, Numerical Python (module name "Numeric"),
a later rewrite called numarray, and an evolution of Numeric that integrates
features from numarray, called NumPy. In the long run, only NumPy will
be maintained and further developed.
MMTK was originally written for Numeric, but has supported NumPy as
well for quite a while. When MMTK is installed, it checks whether
ScientificPython was compiled for Numeric or for NumPy, and uses the
same package. MMTK development is done with NumPy, and Numeric support
will be removed in a future version. Unless you have a good reason to
use Numeric, please use NumPy!
MMTK does not support numarray at all. Since numarray development has
stopped, this is not likely to change in the future.
Platform-specific notes
=======================
This section is based on information I got from MMTK users in the
past. There is a risk that it is not up to date. Any platform-specific
information is welcome!
Windows:
--------
MMTK can be compiled under Windows using the free MinGW compiler
(available from www.mingw.org). You will need to have MinGW setup
properly to compile python extensions, see
http://www.python.org/doc/2.2.1/inst/non-ms-compilers.html for
details. The option "--compiler=mingw32" must be added when running
setup.py.
MMTK can be compiled using Microsoft Visual Studio 6.0 as well. For
more information, check the Wiki pages at:
http://dirac.cnrs-orleans.fr/mmtk_wiki
For using visualization under Windows, you need Mark Hammond's Win32
extensions, available at
http://starship.python.net/crew/mhammond/win32/Downloads.html
Mac OS X:
---------
The most convenient way to use MMTK with MacOS X is through the
MacPorts project, which is located at
http://www.macports.org/
MacPorts provides an install-and-build system for Unix software on the
Mac. You will find many other goodies there, including Python
and many Python packages.
Of course, MacOS X being a variant of Unix, it is also possible
and quite straightforward to install MMTK and all the prerequisites
from source code. Just make sure to have Xcode (Apple's developer
kit) installed.
Using VMD for visualization under MacOS X
-----------------------------------------
The VMD release for MacOS presents itself as a standard Mac application.
Internally, it has the standard Unix command line interface that MMTK
expects, but using the two together requires some particular steps:
1) Create a script called "vmd" in a directory on your shell's
search path (e.g. /usr/bin) containing the following two lines:
#!/bin/bash
xterm -e '/Applications/VMD 1.8.2.app/Contents/Resources/VMD.app/Contents/MacOS/VMD' $*
Don't forget to make this file executable (chmod 755 vmd).
2) Set the environment variable PDBVIEWER to "vmd". The most general
method to do this is by editing the file ~/.MacOS/environment.plist.
The most convenient tool to edit (or create) this file is the
Property List Editor (in Applications/Utilities), but if you feel
comfortable editing XML files, any text editor will do. Note that
changes to this file become active only after the next login.
3) When using VMD from MMTK, make sure to have X11 running (because
the script uses xterm). One way not to forget this is to put
X11 (in /Applications/Utilities) into your startup item list
with the "hide" option selected.
External programs
=================
MMTK uses external programs for visualization and animation. The names
of these programs must be supplied via environment variables. If no
names are provided, the visualization functions will do nothing.
The environment variables are
- PDBVIEWER to specify a program that can show the contents of a
file in the PDB format. The program will be called with the name
of a PDB file as a command line argument.
- VRMLVIEWER to specify a program that can show a file in the
VRML format. The program will be called with the name
of a PDB file as a command line argument.
Animation is implemented only for the programs VMD and XMol.
It is sufficient to specify one of these programs as PDBVIEWER
in order to have access to animation functions.
Documentation
=============
The MMTK manual is included in HTML (Doc/HTML) format. The source code
for the Spinx documentation tool is also included. A list of changes
along MMTK development versions can be found in Doc/CHANGELOG.
Useful tools
============
The directory Tools/TrajectoryViewer contains a small program for
viewing trajectories. It allows that quick inspection of energies,
thermodynamic quantities, etc., as well as animation via an external
viewer.
Web site
========
The MMTK home page can be found at
http://dirac.cnrs-orleans.fr/MMTK/
Mailing list
============
To be informed about updates to MMTK, and to communicate with other
MMTK users, you should subscribe to the MMTK mailing list via
the Web page
http://starship.python.net/mailman/listinfo/mmtk
This is a low-traffic list; there is little reason not to subscribe.
License
=======
MMTK is licensed under the CeCILL-C license. See the file LICENSE for
the text of this license.
Acknowledgements
================
The DCD reader was contributed by Lutz Ehrlich, and uses a C library
for reading DCD files (files Src/ReadDCD.c and Src/ReadDCD.h) which
was written by Mark Nelson at the University of Illinois.
The MolecularSurface module was contributed by Peter McCluskey.
Patches to make MMTK work under Windows were provided by Jon Michelsen.
Peter Cook contributed Windows code, examples, code improvements, and
good suggestions.
Chris Ing translated the documentation to Sphinx, wrote test cases,
and made lots of good suggestions.
Routines for matrix diagonalization were taken from LAPACK, and
for the erfc function from the CEPHES library.
Konrad Hinsen
Centre de Biophysique Moleculaire (CNRS)
Rue Charles Sadron
45071 Orleans Cedex 2
France
E-Mail: hinsen@cnrs-orleans.fr