python --version
prints the version identification message.The downloaded archive file contains three directories:
The defaults.py configuration file, in the Variant directory, contains computer dependent file locations that must be adjusted
in order to have the parts of PyLSD running together. A backup copy named defaults_orig.py has already been created.
Defaults.py lines like self.xxx = yyy
define the value of parameter xxx
as equal to yyy
.
The user is supposed to run pyLSD from the command line, with Variant as current directory.
File edition under Windows may be carried out with the Notepad tool, or alternatively with notepad++.
The following lines may be changed:
self.statuslist = "statuslist.txt"
. This file has by default to be located in the current directory.
Changing the content of this file and its name is possible but not recommanded.
It contains the description of all possible atom status. Do not attempt to create new atom types with a number
of neighbors equal to zero, like a chloride or a sodium ion. This does not work.self.datafolder = os.path.normpath("../LSD/Data")
indicates where pyLSD
stores the pyLSD-generated input, solution and graphics files.self.lsdbin = os.path.normpath("../LSD")
indicates the location of the lsd, outlsd and genpos binary files.
self.rootname = "file"
. pyLSD is able to read input data from the standard input. In that case "file"
is a default root name from which all pyLSD-generated files are named.self.viewerpath = '"C:\\Program Files (x86)\\Ghostgum\\gsview\\gsview32"' if self.isWin else "evince"
.
indicates first where from the Postscript viewer can be launched in a Windows system and then where it can be launched on
a Linux system. The path to the executable file, under Windows, can be simplified if the name of the directory that contains it
has been included is the system environment PATH variable.self.predictorspath = os.path.normpath("../Predict")
is the path to the directory that contains the Java archive
and class files that are needed for chemical shift prediction and solution ranking in the decreasing order of likelihood.self.java = '"C:\\Program Files\\Java\\jdk1.6.0_32\\bin\\java.exe"' if self.isWin else "java"
indicates the path to the java virtual machine. The path to the executable file, under Windows, can be simplified if the name
of the directory that contains it has been included is the system environment PATH variable.self.javamemory = 1024
will allocate 1024 megabytes of memory to java.
Increase value if a Java out-of-memory error occurs.python lsd.py breg57.lsd
A new window with the two solutions of the breg57 problem should pop up on the computer screen.
The resolution of the breg57.lsd problem generates files in the following order:
The absence of some of these files might help to determine if prerequites are not met. A stop after step 3 means that the lsd executable file has not been found. A stop after step 5 means that the outlsd executable file has not been found. A stop after step 6 means that something went wrong with java or with the chemical shift predictor. A stop after step 11 means that something went wrong with genpos. If the .ps file is created after step 12 and is valid but if no window pops up, then the viewer is not accessible. The .coo, .sdf or .ps files may have been created but simply filled with only an error message.
Linux users might feel the need to recompile the LSD binaries from source.
For this purpose, open a command line interpreter, change the current directory to "LSD",
type make clean
, and then sh install.sh
.