Skip to main content

A Python library for parsing XRD pattern files

Project description

Geddes

Crates.io PyPI npm

A Rust XRD pattern parser with Python and Node.js bindings. Supports:

  • .raw (GSAS text or Bruker binary)
  • .rasx (Rigaku Zip archive)
  • .xrdml (Panalytical XML)
  • .xy / .xye (Space-separated ASCII)
  • .csv (Comma-separated values)

Rust Usage

Load from a file path:

use geddes::read;

fn main() {
    let pattern = read("tests/data/xy/sample.xy").unwrap();
    println!("{} {}", pattern.x.len(), pattern.y.len());
}

Load from in-memory bytes (filename is used to infer the format):

use std::fs;

use geddes::read_bytes;

fn main() {
    let data = fs::read("tests/data/xy/sample.xy").unwrap();
    let pattern = read_bytes(&data, "sample.xy").unwrap();
    println!("{} {}", pattern.x.len(), pattern.y.len());
}

Python Usage

Load from a file path:

import geddes

pattern = geddes.read("tests/data/xy/sample.xy")
print(len(pattern.x), len(pattern.y))

Load from in-memory bytes (filename is used to infer the format):

import geddes

with open("tests/data/xy/sample.xy", "rb") as f:
    data = f.read()

pattern = geddes.read_bytes(data, "sample.xy")
print(len(pattern.x), len(pattern.y))

Node.js Usage

Load from a file path:

const geddes = require('@jcwang587/geddes')

const pattern = geddes.read('tests/data/xy/sample.xy')
console.log(pattern.x.length, pattern.y.length)

Load from in-memory bytes (filename is used to infer the format):

const fs = require('node:fs')
const geddes = require('@jcwang587/geddes')

const bytes = fs.readFileSync('tests/data/xy/sample.xy')
const pattern = geddes.readBytes(bytes, 'sample.xy')
console.log(pattern.x.length, pattern.y.length)

License

MIT

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

geddes-0.4.0a0.tar.gz (215.1 kB view details)

Uploaded Source

Built Distributions

If you're not sure about the file name format, learn more about wheel file names.

geddes-0.4.0a0-cp314-cp314-win_amd64.whl (315.3 kB view details)

Uploaded CPython 3.14Windows x86-64

geddes-0.4.0a0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (463.2 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.17+ x86-64

geddes-0.4.0a0-cp314-cp314-macosx_11_0_arm64.whl (410.0 kB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

geddes-0.4.0a0-cp313-cp313-win_amd64.whl (315.1 kB view details)

Uploaded CPython 3.13Windows x86-64

geddes-0.4.0a0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (463.5 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.17+ x86-64

geddes-0.4.0a0-cp313-cp313-macosx_11_0_arm64.whl (410.1 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

geddes-0.4.0a0-cp312-cp312-win_amd64.whl (315.0 kB view details)

Uploaded CPython 3.12Windows x86-64

geddes-0.4.0a0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (464.2 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.17+ x86-64

geddes-0.4.0a0-cp312-cp312-macosx_11_0_arm64.whl (410.0 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

geddes-0.4.0a0-cp311-cp311-win_amd64.whl (316.7 kB view details)

Uploaded CPython 3.11Windows x86-64

geddes-0.4.0a0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (466.2 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

geddes-0.4.0a0-cp311-cp311-macosx_11_0_arm64.whl (411.8 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

geddes-0.4.0a0-cp310-cp310-win_amd64.whl (316.5 kB view details)

Uploaded CPython 3.10Windows x86-64

geddes-0.4.0a0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (466.0 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

geddes-0.4.0a0-cp310-cp310-macosx_11_0_arm64.whl (412.0 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

Details for the file geddes-0.4.0a0.tar.gz.

File metadata

  • Download URL: geddes-0.4.0a0.tar.gz
  • Upload date:
  • Size: 215.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for geddes-0.4.0a0.tar.gz
Algorithm Hash digest
SHA256 1db5471c558dd8a2d66dbffc4637e3bd6caad844f0591f30b612d7d3718e9d04
MD5 39b91109dda25d063f2954d01b576f4d
BLAKE2b-256 7ac7f1c5a120d84ebb8a440b83bf412261bae14aa94ba794ff912bcf33ac386e

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0.tar.gz:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: geddes-0.4.0a0-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 315.3 kB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for geddes-0.4.0a0-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 3b8a834b93f7bcd793fbf51507bd721eb9410df0978b7e4d45a9311408a17635
MD5 92978a40e2f06d1cebd8e8412396dec7
BLAKE2b-256 f5727241ffce135c449ea8485cb64d69da49c2c346b3829f001e292db746844a

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp314-cp314-win_amd64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 7e18a99ddfa1578769db601bc9d8d8c8004f5a8f74e3eb65bf45be39114fe027
MD5 838efe495534170f87da42861cf6f4f7
BLAKE2b-256 80f36e914f12180d9666a0ddfb692821f152a74e65d2ac5d26e71ac66b522bc7

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ee4681b9e62c777a29347c0e3ef63de37907fafe9701f41f9e9cabe53a2065d4
MD5 b53cbce4c43114b71df236e4fbdf9793
BLAKE2b-256 cb456648c65412ed159c3d546dfd0db1377a7282f10b0b4e851a7ba73996f907

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp314-cp314-macosx_11_0_arm64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: geddes-0.4.0a0-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 315.1 kB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for geddes-0.4.0a0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 38eca5678dc95de592992853bd87a7c21dad7c38448a66aec2277926c7434b41
MD5 405eac3abe65b7b5489dfba0f9ad604d
BLAKE2b-256 99f77263657dc7d92acdf15d5f6e112cbc844009b7d061c4030e5afdee5ffffb

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp313-cp313-win_amd64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 43bc5c539263cfd2c98c7d48710bc79868abe2a6ff9e79533e9bcef0445349ef
MD5 d8a9ae81a6127e4c2a202f37c1fb35d0
BLAKE2b-256 51ec810868921cd99ba9ca8c5fdc5a9d83ef381961f3b6025480349c610a5794

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 0f07fd27295756bf8f3d6298a1082ef1029188f521994ea25859024ae2e45ec4
MD5 514c090708f453f528580694bdfeefb4
BLAKE2b-256 22f90b7f173c92acc403bea35b2ae943dc0f7744415fe1cacb5a24c3646e7a35

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp313-cp313-macosx_11_0_arm64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: geddes-0.4.0a0-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 315.0 kB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for geddes-0.4.0a0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 1eddaccd5a23d540b31217bc0aaf2ee94354a80416f79f2dabeaaf0bf7e87154
MD5 eb0749b5d91d7cfbabc4aab9be2a9f35
BLAKE2b-256 1f30c733b3b026fe33dc702e96848925ce5c4c5e9099c74ebf6bc0606e1ca7f0

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp312-cp312-win_amd64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 54f7d9b99798636778e858b1e42f6fcdaa289d35bbdd42b5e1038d6b6334171a
MD5 7c4c89afc695d2b6c40820472117c90e
BLAKE2b-256 e1c348cb84a362d405c4c6b6de60a088db9c584c683690bd1ad42e0152eb95cf

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 9876de6a491a931df64a0c0c27ff4d19a9e4de2f43d941bf7bb97ad41844a4de
MD5 7703b8674fb919280b77510ad0380990
BLAKE2b-256 2fb8c61f73bd57113e5b6843c1e94d1fcae92981515bd525cbce7a747f83f171

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp312-cp312-macosx_11_0_arm64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: geddes-0.4.0a0-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 316.7 kB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for geddes-0.4.0a0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 fe2be0b33444c467c2340b9f4a964903c5937c9f454afd9f2f1538ad3fb00136
MD5 dbf79d9e5c365115b7850a70c2021806
BLAKE2b-256 ad5606e04910bec232e9b3505788203f66434a613a6206e77e22e8055dc17daa

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp311-cp311-win_amd64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 3aba9d68aff92a6ebb0c50ef89ddc806a077924d3100b77830a380de4429cf47
MD5 cf2da27a125d512b8301be4953c680e3
BLAKE2b-256 95189705a16ff868dfeb375c6ba26111de808adaf8909bfe82d30dbb6ba289a4

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 72a754287dc7bc2ce631d826511d0e24983653b7031349da5d3fc308abecb7c8
MD5 8b9c54b5bc3702343aa82dbb0a72458b
BLAKE2b-256 9867c3621f873931913d93e77e4ebb9d24bf3e9378b31760e3d56931e55976e7

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp311-cp311-macosx_11_0_arm64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp310-cp310-win_amd64.whl.

File metadata

  • Download URL: geddes-0.4.0a0-cp310-cp310-win_amd64.whl
  • Upload date:
  • Size: 316.5 kB
  • Tags: CPython 3.10, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for geddes-0.4.0a0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 b8b4fc521e7a28c441261d86c54e9b1b53fd3b704a086bb0e4abaf0752fdcaf0
MD5 28ff48278077c656247182d00780bd19
BLAKE2b-256 5a248969e9624afd4726a1e82863530d03131b957ddad76fe51d4350891d96dd

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp310-cp310-win_amd64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 b4af5db3116ff6d03dd4697713975e19410ce9a9a48a2713af1938a05e997dcb
MD5 0ddbe42b14a3a9d622445a654c768805
BLAKE2b-256 5057d8b9e3b9e19792ec9fa3ce0e68feac5235ffebe5dc2695a6259d69de1f9d

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file geddes-0.4.0a0-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.4.0a0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 11912957f103593ca41aa01b966670b1dd6fd6e8111ea10d4f0d4fc910aba7c9
MD5 c81bd0fa9a9050b607186f92e09e6bdc
BLAKE2b-256 369d8fd01f5164fd1a29365d7b6218e51fb18595f320ff62a1e0cc12b83b6821

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.4.0a0-cp310-cp310-macosx_11_0_arm64.whl:

Publisher: publish-pypi.yml on jcwang587/geddes

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

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