Linux
Install ASE inside Blender
On Linux and MacOS, go to your Blender python directory, e.g. blender-3.4.0-linux-x64/3.4/python/bin
, install pip:
$ ./python3.10 -m ensurepip
$ ./python3.10 -m pip install --upgrade pip
Install ASE and scikit-image inside Blender:
$ ./pip3 install --upgrade ase
$ ./pip3 install scikit-image
Install batoms inside Blender
Download the latest version (beautiful-atoms.zip).
Extract the file, move the folder
batoms
to Blender addons folder$HOME/.config/blender/3.4/scripts/addons/
.Enable the addon in the Preferences setting. Please open a Blender Python console, and run the following code to enable the batoms:
import addon_utils import bpy addon_utils.enable('batoms', default_set=True) bpy.context.preferences.view.use_translate_new_dataname = False bpy.ops.wm.save_userpref()
Note
Or, you can visit here to learn how to enable an addon by hand. https://docs.blender.org/manual/en/latest/editors/preferences/addons.html.
Test your installation
Start Blender, in the python console, run:
>>> from batoms import Batoms
>>> h2o = Batoms('h2o', species = ['O', 'H', 'H'],
... positions= [[0, 0, 0.40], [0, -0.76, -0.2], [0, 0.76, -0.2]])
If you saw a water molecule, you have run a successful installation, congratulations!
Install batoms-api on your computer (Optional)
First install ASE on your computer. On Linux, open a terminal, and run:
$ pip3 install --upgrade ase
$ pip3 install batoms-api
Then set a BLENDER_COMMAND
environment variables. Set these permanently in your ~/.bashrc
file:
export BLENDER_COMMAND='<path-to-blender>/blender'