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.2.0a0.tar.gz (182.8 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.2.0a0-cp314-cp314-win_amd64.whl (307.8 kB view details)

Uploaded CPython 3.14Windows x86-64

geddes-0.2.0a0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (463.6 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.17+ x86-64

geddes-0.2.0a0-cp314-cp314-macosx_11_0_arm64.whl (399.9 kB view details)

Uploaded CPython 3.14macOS 11.0+ ARM64

geddes-0.2.0a0-cp313-cp313-win_amd64.whl (307.5 kB view details)

Uploaded CPython 3.13Windows x86-64

geddes-0.2.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.2.0a0-cp313-cp313-macosx_11_0_arm64.whl (400.2 kB view details)

Uploaded CPython 3.13macOS 11.0+ ARM64

geddes-0.2.0a0-cp312-cp312-win_amd64.whl (307.6 kB view details)

Uploaded CPython 3.12Windows x86-64

geddes-0.2.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.2.0a0-cp312-cp312-macosx_11_0_arm64.whl (399.6 kB view details)

Uploaded CPython 3.12macOS 11.0+ ARM64

geddes-0.2.0a0-cp311-cp311-win_amd64.whl (309.2 kB view details)

Uploaded CPython 3.11Windows x86-64

geddes-0.2.0a0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (465.5 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.17+ x86-64

geddes-0.2.0a0-cp311-cp311-macosx_11_0_arm64.whl (400.6 kB view details)

Uploaded CPython 3.11macOS 11.0+ ARM64

geddes-0.2.0a0-cp310-cp310-win_amd64.whl (309.2 kB view details)

Uploaded CPython 3.10Windows x86-64

geddes-0.2.0a0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (465.9 kB view details)

Uploaded CPython 3.10manylinux: glibc 2.17+ x86-64

geddes-0.2.0a0-cp310-cp310-macosx_11_0_arm64.whl (401.0 kB view details)

Uploaded CPython 3.10macOS 11.0+ ARM64

File details

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

File metadata

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

File hashes

Hashes for geddes-0.2.0a0.tar.gz
Algorithm Hash digest
SHA256 36c7788d712073bb0d54591131d96aa85c7986b07f411b507e301dd18c3b9e19
MD5 f3f4bca07fe3526e50ca3f6f4d2f5373
BLAKE2b-256 3651b43ca8407324dede0ec12ba10dd4eefc2212319b90b83c2d7f4ac94819ff

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp314-cp314-win_amd64.whl.

File metadata

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

File hashes

Hashes for geddes-0.2.0a0-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 68acfc919ea9be956585859a5bd9c71f33b7ad98164fa636fc578e28b63be17e
MD5 be129be7b93c50f86132d1a3c640da57
BLAKE2b-256 9ed141ce667991067574854736a977a9d0654a0066d3d1d2181303e498edd61b

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp314-cp314-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 c2a41a91cb407909faca8ba8f27b16df47f7415d57972a8e6e3f36cb93a22109
MD5 67192e3d1a1f9289ca0c584bae357485
BLAKE2b-256 c0c192131f61c6770dfd8e598aa0c098d4ce1f2ae1984d196ecf04a449329eda

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp314-cp314-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp314-cp314-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 553948d5dfb7c7860be1c14f4fba8fc82214f95da7240c83b38a0c9bdc527cd3
MD5 69543df87faa2437f617b877a2b513b0
BLAKE2b-256 5cdd325fda6012471cd5d82c94356ff875cd028363562e9eec2514e448fba9e7

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp313-cp313-win_amd64.whl.

File metadata

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

File hashes

Hashes for geddes-0.2.0a0-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 b60bdc20aa468953f6c81f3c58a15ad8387e531082736d5e627ba869065441d8
MD5 55bdce353fd0f0f32eeb048a29d567a2
BLAKE2b-256 ef4e8c9cd67a8e2328588f457f816de750b9b2d0858a410368aa96f236a96e4c

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp313-cp313-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 9c69d11e2e29b0d5ae368e82e5514bdb00c67ac7c43cf88b998d12eae89f52d8
MD5 029ad1fc6d4f04636c3a0d58532ee4b3
BLAKE2b-256 7b525c5124b38b7cd1e0926db73cd519dd57a688e74edab420ad264822aee07d

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp313-cp313-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp313-cp313-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 79f4aadf7b0e28232ba24d60d1fcd602245f990317705636125bff53fe0482af
MD5 c6ab9b51ae2e93417748240d676652f1
BLAKE2b-256 467b9096196783d6687319e844c8696764f0ab72634084afed13afac5742270f

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp312-cp312-win_amd64.whl.

File metadata

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

File hashes

Hashes for geddes-0.2.0a0-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 5d36d24493b3ff55c769c76cb9684f77c66f0712a024411a0af013228a7f77ea
MD5 9ed66ce79f6d94df55baedd25c46b07c
BLAKE2b-256 a8b0c0c042b05235edaf9e80bd1b70d649985004fc37320221c40c9233fdb326

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 44522362d6b1610a47e194f22c3af4d12009c0b7decfdd2134735b157a6cc417
MD5 b021cd509842284c5bff7772fea51162
BLAKE2b-256 4e116f55b015faf70ccd9687bc5e99de5125871683dc9c0891f49f0ad4433061

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp312-cp312-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp312-cp312-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 48cf4a9100a7e0485bc45ff0b0a76f6feb81746f01fd2ffbcc2361d1873aa7d6
MD5 0f9d2deb5125ca98451c7895e316a3fa
BLAKE2b-256 2b3ccd51372a5a95ab5be6200e44d44f7cd67fc5ff8871ff27525fb8977fca43

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp311-cp311-win_amd64.whl.

File metadata

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

File hashes

Hashes for geddes-0.2.0a0-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 407ed8a242063a318cdd45cad7eb8870e23a25b7517695e69774013cbcaa3ce4
MD5 b9d181ea2135f8e714702aceadd2c20a
BLAKE2b-256 8e44b91e74ff9ad989ce64658cbe080fc75819f10c5b59f8535e4a62d3a1ed4c

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 ff86ebedeffa9de3a01dae753afa0437a0115c2bb16774b2267101e52181d920
MD5 f9094e2c9a00c27857890208f7175b01
BLAKE2b-256 1bd11350bec55192250b3f2ba93980dce57ae657afa1e3ad0745e801f7c3b553

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp311-cp311-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp311-cp311-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 3feacf856c3436b35ef061dc2ba75c58a0d26e8f90e68d40b7786dc9ffd9435a
MD5 742695d3f56facb01e0a20915048f90b
BLAKE2b-256 d7976b6478bf10b8058f3b101f527389fc9b6138fb826d6752d951cbbe3f4e59

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp310-cp310-win_amd64.whl.

File metadata

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

File hashes

Hashes for geddes-0.2.0a0-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 d29b6d3e1f6c70eb3d8ce98a556433ed2ce56fd6781740b2b7eaeae3af577f4b
MD5 179aa640e2f4879ce0499be99e9c709b
BLAKE2b-256 5dfb02deb2445f817aaca8074c4db82f6a6692bf69554b34374f3137fa892118

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 ebe921c0c60db3979c641b7cc8732c6abc0e22c2e75f7d1cb0e845f5e355d8e3
MD5 f5f0da8a7faec96d4f7febc8a3c3a090
BLAKE2b-256 5a96244b75122909c7f73c7ea934d246818ddd5d7ea2b05db9390a2a314d6a21

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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.2.0a0-cp310-cp310-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for geddes-0.2.0a0-cp310-cp310-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 883fc0b492b382a52648f7e654298e2013bfb8701e23944190fb208f8bb4126a
MD5 39917e923e0edd5ed2849a79722cae33
BLAKE2b-256 47676b949c2c4c890a4a6d652163387ca3feb15671deb933283968c7f24c6233

See more details on using hashes here.

Provenance

The following attestation bundles were made for geddes-0.2.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