Skip to main content

Package for converting CASTEP .phonon files to .json files.

Project description

phonon-to-json

Converts CASTEP .phonon files into .json files readable by TSS Physics Phonon Visualiser.

Install

To install phonon-to-json run:

pip install phonon-to-json

Dependencies

phonon-to-json requires

Command line

phonon-to-json is designed to be run as a command line tool. To run:

phonon_to_json [filename] [name] [formula]
  • [filename] is the name of the .phonon file (excluding the .phonon extension)
  • [name] is the name of the compound, as displayed at the top of the website
  • [formula] is the chemical formula of the compound

[name] and [formula] are optional, if ommited [filename] will be used

As a module

To use phonon-to-json as a module import json_dumper:

import phonon_to_json as pj

filename = "[filename]"
name = "[name]"
formula = "[formula]"

r_data = pj.read_file(filename)
w_data = pj.read_to_write(r_data, name, formula)
pj.write_file(filename, w_data)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

phonon_to_json-0.0.3.tar.gz (41.7 kB view details)

Uploaded Source

Built Distribution

phonon_to_json-0.0.3-py3-none-any.whl (10.8 kB view details)

Uploaded Python 3

File details

Details for the file phonon_to_json-0.0.3.tar.gz.

File metadata

  • Download URL: phonon_to_json-0.0.3.tar.gz
  • Upload date:
  • Size: 41.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.1.1 CPython/3.12.7

File hashes

Hashes for phonon_to_json-0.0.3.tar.gz
Algorithm Hash digest
SHA256 b7c681e055ea26e3234e07c4fc75e5090a8f19d31929609ce645c130ec3235a9
MD5 c0fb95aea2986218a018d38ce021529c
BLAKE2b-256 4c01cc5c15b3cdb4585b5fdb02a8d3b06284034be8282ffc3cb8e61cb0f1968e

See more details on using hashes here.

File details

Details for the file phonon_to_json-0.0.3-py3-none-any.whl.

File metadata

File hashes

Hashes for phonon_to_json-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 bd6378e1e6af2eeb1ef9667b8af8c85b551f280cb044b8f16499389c43c3f54f
MD5 c75547bcaf9d0c909948a9fad945e93b
BLAKE2b-256 fe4676e6379d34c2f55f5b074804353bb5dd49eb9b0b4f8bca1b3ec92cdf2007

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page