QSTEM is a program for quantitative image simulation in electron microscopy, including TEM, STEM and CBED image simulation.
This project interfaces the QSTEM code with Python and the Atomic Simulation Environment (ASE) to provide a single environment for building models, simulating and analysing images.
This program is no longer be maintained here. You may instead be interested in this new Python-based multislice simulation program.
QSTEM webpage: http://qstem.org/ ASE webpage: http://wiki.fysik.dtu.dk/ase
Optional:
FFTW is installed with apt-get, the rest with pip.
sudo apt-get install libfftw3-dev libfftw3-single3
pip install numpy scipy matplotlib ase
pip install cython jupyter scikit-image
When the dependencies are installed, download, compile and install PyQSTEM by writing.
git clone https://github.com/jacobjma/PyQSTEM.git
cd pyqstem
python setup.py install
You might get some warnings which can be ignored.
Mac OS X comes with Python included, but installing packages into OS X's own Python is risky, as cleaning up a mess is almost impossible. For this reason, it is recommended to either install Python with Homebrew, or to install the Anaconda distribution. This guide uses homebrew's Python, as you will need to install a number of other packages with Homebrew anyway.
Install Homebrew following the instructions on the Homebrew website.
Install Homebrew's python with the command
brew install python
or if you want Python 3 with
brew install python3
Please double-check that you get the version of python
and pip
installed in /usr/local/bin, and not the default one in /usr/bin.
FFTW is installed with Homebrew, the rest with pip.
brew install fftw
pip install numpy scipy matplotlib ase
pip install cython jupyter scikit-image
When the dependencies are installed, download, compile and install PyQSTEM by writing.
git clone https://github.com/jacobjma/PyQSTEM.git
cd PyQSTEM
python setup.py install
You might get some warnings which can be ignored.
If you are new to Python the easiest way to get started is downloading a bundle installer. We recommend Anaconda, this platform includes Python and makes it easier to install the dependencies. Download Anaconda here.
Compiling C++-extensions for Python 3.5 on Windows requires Microsoft Visual C++ 14.0 or later. Download Visual C++ 2015 Build Tools from here, this requires 4 gb of free space and may take 20 minutes to install.
If you are using Python 2.7 you can install TDM-GCC and in the Anaconda prompt write
conda install mingw libpython
Precompiled libraries for FFTW 3.3.5 are included for both 32 and 64-bit Windows. You should not have to do anything.
When Anaconda and a C++-compiler is installed, open the Anaconda prompt
, and type the following commands to install ASE, cython and the rest of the dependencies:
pip install numpy matplotlib ase
conda install cython scipy
The other required dependencies should be included with Anaconda, otherwise install them using pip
.
When the dependencies are installed, download, compile and install PyQSTEM by writing.
git clone https://github.com/jacobjma/PyQSTEM.git
cd pyqstem
python setup.py install
You might get some warnings which can be ignored.