https://github.com/zhubonan/vesta-colour-scheme
Manipulating colours use in VESTA
https://github.com/zhubonan/vesta-colour-scheme
Last synced: 2 months ago
JSON representation
Manipulating colours use in VESTA
- Host: GitHub
- URL: https://github.com/zhubonan/vesta-colour-scheme
- Owner: zhubonan
- License: mit
- Created: 2021-08-05T16:49:30.000Z (almost 4 years ago)
- Default Branch: master
- Last Pushed: 2021-09-26T11:17:54.000Z (over 3 years ago)
- Last Synced: 2025-02-05T11:52:55.356Z (4 months ago)
- Language: Python
- Size: 651 KB
- Stars: 3
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# vesta-colour-scheme
Manipulating [VESTA](https://jp-minerals.org/vesta/en/) save files to apply user-defined colours.
This package provides an python inteface for reading/writing VESTA save files. It is very basic but serves the goal of changing colours well.
Picking a good colour scheme can quickly become non-trivial for systems with three or more elements.
The colour scheme should be sufficient for distinguishing different species, while not having too much "contrast" to strain the eye.VESTA stores the default colours in the `elements.ini` inside the installation folder.
However, changing the `elements.ini` does not affect existing `.vesta` files that has been saved.
While colours of each species can be picked manually using GUI, the process of applying this to many `.vesta` files quickly becomes time-consuming and boring (especially for last-minute changes).This package provides a command-line tool for applying a colour scheme, defined in a `*.yaml` file, to existing `.vesta` files.
This allows different colour scheme can be trialed and applied to a range of `.vesta` files easily.
## Installation
```
pip install git+https://github.com/zhubonan/vesta-colour-scheme.git#egg=vesta-colour-scheme
```## Usage
Commandline interface:
```
Usage: vesta-colour-scheme [OPTIONS] [VESTA_FILE]...Apply a predefined colour scheme to a VESTA file
Options:
--scheme FILENAME
--backup / --no-backup
--verbose
--help Show this message and exit.
```Example colour scheme file (`colours.yaml`):
```
Te:
rgb: 887BB0
Cd:
rgb: 85D2D0# Integer RGB values also works
#Cd:
# rgb: [100, 200, 0]
```Once the `.vesta` file is updated, it must be re-opened with VESTA to see the changes.
An example `colours.yaml` can be found inside the `examples` folder.