Installing GSAS-II - Overview - GSAS-II Web Documentation 1.0 Documentation
Installing GSAS-II - Overview - GSAS-II Web Documentation 1.0 Documentation
0 documentation
1.1.1. Windows
1.1.2. MacOS
https://advancedphotonsource.github.io/GSAS-II-tutorials/install.html?authuser=0#macos 1/5
11:03 21/1/25 1. Installing GSAS-II: Overview — GSAS-II web documentation 1.0 documentation
g2=”https://github.com/AdvancedPhotonSource/GSAS-II-
buildtools/releases/download/v1.0.1/gsas2full-Latest-MacOSX-x86_64.sh” curl -L “$g2”
> /tmp/g2.sh; bash /tmp/g2.sh -b -p <install-loc>
Note that the MacOSX-x86_64.sh installer will run on “Apple Silicon” processors, but sig‐
nificantly more slowly.
where:
1.1.3. Linux
where:
The pages listed below go through the GSAS2FULL installation process on each identified
platform in much greater detail.
https://advancedphotonsource.github.io/GSAS-II-tutorials/install.html?authuser=0#macos 2/5
11:03 21/1/25 1. Installing GSAS-II: Overview — GSAS-II web documentation 1.0 documentation
This creates a conda virtual environment named GSASII (this can be changed) for use by
GSAS-II. While it is also possible to install GSAS-II into the conda base environment, this
is not recommended as it can create conflicts between Python and package versions need‐
ed by GSAS-II and those required by other packages. (If you choose to do this anyway, be
sure to specify conda install python=3.11 briantoby::gsas2pkg as Python is likely to
be pinned to a different version.)
After this command is run, use command conda activate GSASII to access the conda
environment that has been created. On Linux and MacOS computers, two shortcut com‐
mands will then be available in the path, The first command, gsasII.sh , which will start
GSAS-II. This can optionally be used as gsasII.sh project.gpx to open existing project
file project.gpx in GSAS-II. The second command, reset-gsasII.sh will rarely be used.
This command will download the latest version of GSAS-II and update to that version, re‐
placing any locally modified files with the original versions. This can be used to update
GSAS-II when the program will not start, so the normal Help->Update menu command
cannot be accessed. (Shortcuts available with gsas2pkg v5.1+.)
Note that on MacOS, a Mac app is also created and is displayed in the Finder see steps 5 &
6 here. This app can be used to start GSAS-II from the dock or desktop.
https://advancedphotonsource.github.io/GSAS-II-tutorials/install.html?authuser=0#macos 3/5
11:03 21/1/25 1. Installing GSAS-II: Overview — GSAS-II web documentation 1.0 documentation
other than those recommended are selected (Python=3.11 and NumPy=1.26), you will like‐
ly need to either locate older binaries and install them manually or compile them yourself
(see compilation information).
A simple way to install GSAS-II with a supplied Python environment uses the gitstrap.py
script provided for this purpose. Use these commands (on any platform) to install GSAS-
II:
cd ~/G2
curl -L -O https://github.com/AdvancedPhotonSource/GSAS-II-buildtools/raw/main/install/g
python gitstrap.py
This will place the install script in directory ~/G2 (which you may wish to change) and will
place all GSAS-II files in subdirectory ~/G2/GSAS-II
Note that you can also clone the GitHub repo. If you do this, the GSAS-II binary files will
not be installed. However, when GSAS-II is first run, it will provide an opportunity to do
this.
https://advancedphotonsource.github.io/GSAS-II-tutorials/install.html?authuser=0#macos 5/5