Helpers to work with the chemiscope interactive structure/property explorer for materials and molecules
Project description
Python helpers for chemiscope
This package contains Python code to help generate input files for the chemiscope default visualizer, and integrate chemiscope with jupyter notebooks.
Installation
You should use pip to install this package:
pip install chemiscope
This installs both a chemiscope-input
command line tool, and the chemiscope
package.
Usage
To create a new chemiscope input file:
import chemiscope
import ase.io
# read frames using ase
# frames can also be stk objets, e.g.
# frames = [stk.BuildingBlock(smiles="NCCN")]
frames = ase.io.read("structures.xyz", ":")
# add additional properties to display
properties = {
"<property name>": {
target: "atom",
values: [3, 4, 2, 8, 9, 10],
}
}
chemiscope.write_input("my-input.json.gz", frames=frames, properties=properties)
To display a chemiscope widget inside a jupyter notebook:
import chemiscope
import ase.io
# read frames using ase
# frames can also be stk objets, e.g.
# frames = [stk.BuildingBlock(smiles="NCCN")]
frames = ase.io.read("structures.xyz", ":")
# add additional properties to display
properties = {
"<property name>": [3, 4, 2, 8, 9, 10],
}
chemiscope.show(frames=frames, properties=properties)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
chemiscope-0.8.3.tar.gz
(3.7 MB
view details)
Built Distribution
File details
Details for the file chemiscope-0.8.3.tar.gz
.
File metadata
- Download URL: chemiscope-0.8.3.tar.gz
- Upload date:
- Size: 3.7 MB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6e99661c912b72202280912e32126c5ea8709642e1e064259153e5243ff90ee6 |
|
MD5 | 3170d8b310c0a79aa166be9526a2f72e |
|
BLAKE2b-256 | 7a6d798ff928393d35c02d2184cab3bcace03ff49bf95565afcd92b7145a069d |
File details
Details for the file chemiscope-0.8.3-py3-none-any.whl
.
File metadata
- Download URL: chemiscope-0.8.3-py3-none-any.whl
- Upload date:
- Size: 3.8 MB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.1 CPython/3.12.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3bc1a6e44c440c941cd92fae843fb9ca748739467a14edb3b82c27054b9560d3 |
|
MD5 | d88d188fcfacea0392e05a7d3d144761 |
|
BLAKE2b-256 | 1ca2af5acfa2266803dd8afdb3f400cf4f9689a5fe478f8a8e73bd9319bc14c9 |