Version 5 (modified by toby, 5 years ago) (diff) |
---|
Installing GSAS-II for Linux with a Single-Step Download
A new approach for downloading and installing GSAS-II, along with required prerequisites has been developed using tools from Anaconda Inc. (previously Continuum Analytics) and their Anaconda free product. (Thanks Anaconda!.) Downloading one file (~300 Mb) provides: Python, a number of Python packages, and subversion (svn), which is then used to install GSAS-II. The svn program is also used to update GSAS-II (using the Help/Update menu command) as changes are made.
Step 1:
Download one of the following:
- https://subversion.xray.aps.anl.gov/admin_pyGSAS/downloads/g2conda-1.0.1-Linux-x86_64.sh
- This has the latest Python & wxPython versions. It may have a few compatibility bugs we have not yet seen.
- https://subversion.xray.aps.anl.gov/admin_pyGSAS/downloads/g2conda-py27-1.0.2-Linux-x86_64.sh
- This has more tried-and-true Python (2.7.x) and wxPython (3.0.x) versions and may be a bit more safe, but we will eventually move to the above.
or
- https://anl.box.com/v/GSASII4linux12 (file g2conda-0.1.2-Linux-x86_64.sh)
- this is older and is not recommended, unless you have a older Linux dist
Note that regardless of which installer you use above, this process will always install the latest version of GSAS-II.
Step 2:
Execute the downloaded file. This should be done by typing the command
bash <path>/g2conda-*-Linux-x86_64.sh
in a terminal window. Then press Enter to run the command.
Step 3:
Answer prompts from the install script.
- Press enter to start the procedure
- Press enter to read through the copyright notice
- type "yes" to accept the copyright information and start the installation.
- Enter a location for where the files should be loaded, if the default is not OK and press enter. If the default is OK, simply press enter. Problems have been reported when the directory name includes spaces.
- Wait while the installation of Python, etc occurs. There will typically be a long delay while nothing happens followed by a series of messages as packages are installed.
Step 4:
After Python and packages are installed, the GSASII/bootstrap.py file (also called bin/gsas2-install.py) is invoked to install the GSAS-II files using program svn (subversion) from the APS server https://subversion.xray.aps.anl.gov/pyGSAS
This script requests the name of a proxy server. Most people will use the default and press return. However, some sites block web traffic unless it is passed through a particular computer. If needed, enter that computer name or IP address here (e.g. proxyout.lanl.gov); you will be then be requested to also supply a port number, which defaults to 8080.
Note that the location of the Python image is displayed (typically ~/g2conda/bin/python) this is worth noting in case you have installation problems and need to rerun the bootstrap.py script.
Once the svn command is executed a large number of files are downloaded ending with display of the current GSAS-II version number.
The final question to be asked is should the installation location be placed into your system's path. Answering "no" is recommended (unless you plan to run other Python scripts from the command line with this version of Python, in which case you may want to type "yes".)
The Python and GSAS-II installation is now complete, and you can close the terminal window.
On some Linux distributions a shortcut will be created to run GSAS-II, for example on the desktop. On others you will need to do this yourself. Note that the command to run GSAS-II will be something like this
~/g2conda/bin/python ~/g2conda/GSASII/GSASII.py
but the prefix ~/g2conda/ will vary depending on where you install GSAS-II.
In case of problems
This installation process is undergoing revisions, so please report problems, unclear instructions to [Brian dot Toby at ANL dot gov] (notes about success are also appreciated).
If you are able to download the g2conda-*-MacOSX-x86_64.sh file, but have a problem installing it, you may not be executing the command properly. Please make sure you are typing bash correctly and leaving a space between that and the file name, also be sure you are allowed to write files to the location you choose for installation. If the installation fails, delete the previous installation directory before trying again.
If you are able to install the Python files, but the downloading of GSAS-II fails (Step 4), you may need to specify a proxy; contact a computer/network support person for your institution. While it may be simpler to delete the directory where you have installed the files (typically .../g2conda) and resume from Step 2, it is also possible to rerun the bootstrap.py file using a command such as
~/g2conda/bin/python ~/g2conda/GSASII/bootstrap.py
where ~/g2conda may need to be changed to the location where these files have been installed.