Skip to main content

Reader/Writer library for irap files.

Project description

surfio

Surfio is a library for reading and writing surface files. Currently only supports the irap format.

Installation

pip install .

Usage

Irap surfaces can be imported using the from_ascii_file, from_ascii_string, from_binary_file and from_binary_buffer methods of IrapSurface.

import surfio


surface = surfio.IrapSurface.from_ascii_file("./file.irap")
print(surface.header.ncol, surface.header.nrow) # 10, 11
print(surface.values.shape) # (10, 11)

from_ascii_file is equivalent to

with open("./file.irap") as f:
    surface = surfio.IrapSurface.from_ascii_string(f.read())

but is more performant.

Exporting irap surfaces can be done with

    surface = surfio.IrapSurface(
        surfio.IrapHeader(
            ncol=3,
            nrow=2,
            xori=0.0,
            yori=0.0,
            xinc=2.0,
            yinc=2.0,
            xmax=2.0,
            ymax=2.0,
            rot=0.0,
            xrot=0.0,
            yrot=0.0,
        ),
        values=np.zeros((3, 2)),
    )
    surface.to_ascii_file("./file.txt")

which is equivalent to:

with open("./file.irap", mode="w") as f:
    f.write(surface.to_ascii_file())

Development

pip install -e ".[dev]"

Style is enforced via pre-commit:

pre-commit install

C++ development

To configure the project

cmake --preset release-posix

To build it

cmake --build --preset release-posix

To test it

ctest --preset release-posix

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

surfio-0.0.21-cp314-cp314-win_amd64.whl (205.9 kB view details)

Uploaded CPython 3.14Windows x86-64

surfio-0.0.21-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (340.9 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

surfio-0.0.21-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl (307.3 kB view details)

Uploaded CPython 3.14manylinux: glibc 2.26+ ARM64manylinux: glibc 2.28+ ARM64

surfio-0.0.21-cp314-cp314-macosx_15_0_arm64.whl (3.1 MB view details)

Uploaded CPython 3.14macOS 15.0+ ARM64

surfio-0.0.21-cp313-cp313-win_amd64.whl (201.4 kB view details)

Uploaded CPython 3.13Windows x86-64

surfio-0.0.21-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (340.8 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

surfio-0.0.21-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl (306.9 kB view details)

Uploaded CPython 3.13manylinux: glibc 2.26+ ARM64manylinux: glibc 2.28+ ARM64

surfio-0.0.21-cp313-cp313-macosx_15_0_arm64.whl (3.1 MB view details)

Uploaded CPython 3.13macOS 15.0+ ARM64

surfio-0.0.21-cp312-cp312-win_amd64.whl (201.3 kB view details)

Uploaded CPython 3.12Windows x86-64

surfio-0.0.21-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (340.9 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

surfio-0.0.21-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl (306.0 kB view details)

Uploaded CPython 3.12manylinux: glibc 2.26+ ARM64manylinux: glibc 2.28+ ARM64

surfio-0.0.21-cp312-cp312-macosx_15_0_arm64.whl (3.1 MB view details)

Uploaded CPython 3.12macOS 15.0+ ARM64

surfio-0.0.21-cp311-cp311-win_amd64.whl (201.0 kB view details)

Uploaded CPython 3.11Windows x86-64

surfio-0.0.21-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl (341.1 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.27+ x86-64manylinux: glibc 2.28+ x86-64

surfio-0.0.21-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl (306.0 kB view details)

Uploaded CPython 3.11manylinux: glibc 2.26+ ARM64manylinux: glibc 2.28+ ARM64

surfio-0.0.21-cp311-cp311-macosx_15_0_arm64.whl (3.1 MB view details)

Uploaded CPython 3.11macOS 15.0+ ARM64

File details

Details for the file surfio-0.0.21-cp314-cp314-win_amd64.whl.

File metadata

  • Download URL: surfio-0.0.21-cp314-cp314-win_amd64.whl
  • Upload date:
  • Size: 205.9 kB
  • Tags: CPython 3.14, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for surfio-0.0.21-cp314-cp314-win_amd64.whl
Algorithm Hash digest
SHA256 80d34f3217e201f8554b806ea68291e20c6030e46a5389094a7a3da630077a08
MD5 5109d6568cee183b8542796f24f1969c
BLAKE2b-256 4c0280c0055abf0fd719f80c0201a4a95c394e985ec30c7d5fa44ee39cea77be

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp314-cp314-win_amd64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 4926c767475c417a09953f4ac7716da0dd60031144130bbd9351cea537f0e487
MD5 fc2d54ebb90382273b1b277d4e0298b8
BLAKE2b-256 406e55f44fc24eddca9c0861d5acf88811e670beccafbca6148185b4d8b52510

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp314-cp314-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 9b327e7f4145a4be5d13a0980b20abfdb0654eba8fd86c328c2971d9905f0dba
MD5 b9bd87e72f46e8f5848bd0a548a68e44
BLAKE2b-256 efd88e29687496ecfad533225cc74203567b7b4a9e388fb6276b11da5df0228f

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp314-cp314-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp314-cp314-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp314-cp314-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 2ba77f03603e39683df4ed4e4eb0e77d4688e4d74d02ec337a2367e6a3065950
MD5 d76d70ffbda7039e48f839a32c6885a5
BLAKE2b-256 4ce095b1303d1cadc6e91a982b1d8822274ebf580db181727a031b43accbe3ba

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp314-cp314-macosx_15_0_arm64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp313-cp313-win_amd64.whl.

File metadata

  • Download URL: surfio-0.0.21-cp313-cp313-win_amd64.whl
  • Upload date:
  • Size: 201.4 kB
  • Tags: CPython 3.13, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for surfio-0.0.21-cp313-cp313-win_amd64.whl
Algorithm Hash digest
SHA256 55687d47d13ea00314e4651efdd83375792d8af135957e615f147a8d58d8fd55
MD5 96bb576af445dc7bf32aca47dd743db7
BLAKE2b-256 3debf77240c019c855ba5ef7753b6520e932a46e5bd27faa0ff05d7e0d6f9007

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp313-cp313-win_amd64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 ddb131c6b12d9a4a8ab46e707a5f90faccc8a51fc1573dc2aaa2e5020efe2c47
MD5 a0fad353cb70627b8b02411075105a04
BLAKE2b-256 a181e7d8945dd666c5eafbbeca40a83486ecf13aaa7199ba999f388958c02ff7

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp313-cp313-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 1c861a2b59e226b625843ab430f1d0ea8041fa95e24788be5f2a098ad50709c3
MD5 2143d769421cf0319d72498a884ed9cb
BLAKE2b-256 a5a04cab04ef5782a027164934ab93f1a71b32d1c66ad03877a89aa04e93c84a

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp313-cp313-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp313-cp313-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp313-cp313-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 29517c862f932b33c4efbdb18fb07e2c76b6c2fc8194b579f0209ea3f49bce2d
MD5 daeae42ea7c8175eb106c049d8d92d17
BLAKE2b-256 1872d7f10e74476a64c3087032d94d6f5fd028ae10626caf5219d69ef30b8ad4

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp313-cp313-macosx_15_0_arm64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp312-cp312-win_amd64.whl.

File metadata

  • Download URL: surfio-0.0.21-cp312-cp312-win_amd64.whl
  • Upload date:
  • Size: 201.3 kB
  • Tags: CPython 3.12, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for surfio-0.0.21-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 53c6c85e96f40c2952bb263529f018a83299d0583b607ef1333e1d73d86425c5
MD5 7031705d8b4ea49f5c2c0d9406b1130a
BLAKE2b-256 96d02d6a3d979bc5833b38b754c837f3328930f3d917e0b4a604a2db8b3ace56

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp312-cp312-win_amd64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 f8d7b89e2cc17d9a3a159fddcfd453fce81b439740944298c41036eb2280c446
MD5 3fdba29e90fdeb8ef4342143b19034c1
BLAKE2b-256 3b30f3730d3c0a49e6e1dc275e67dfb53f93ddda492b62c801c36a4ebdc7ea9e

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp312-cp312-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 61f6b1a8d7dc31f0970457a32eff4c8b50a67f5f2c824149ed477dd3d88847f9
MD5 c600215af32d3bc442682fb157c0be10
BLAKE2b-256 9af90a33377cc5f5d8994dc89bb3b5a7642d629ac1ef441fd2b2e038ef2141a5

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp312-cp312-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp312-cp312-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp312-cp312-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 37b7a2a44c62ecb3d0519519f664e4b30bd3ba82985a6c93628e44e24fdd6c5a
MD5 2df33874b1bd398e910efdd87a60fb7f
BLAKE2b-256 768e522b066c1604dc72fb96be2ae3239d64107a2820cf7b618e1a2b567f906a

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp312-cp312-macosx_15_0_arm64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp311-cp311-win_amd64.whl.

File metadata

  • Download URL: surfio-0.0.21-cp311-cp311-win_amd64.whl
  • Upload date:
  • Size: 201.0 kB
  • Tags: CPython 3.11, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.13

File hashes

Hashes for surfio-0.0.21-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 9c1c6de41e38cdb881cfb1b60a0984693dd9466e375c4e857c260786bb3a4007
MD5 9f1f89071299be4c4d252e63633f1f0b
BLAKE2b-256 8781a300e3c91fbcb8c29a73eedb09e5cfa0ec07aec0b970b13b195513ed9553

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp311-cp311-win_amd64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl
Algorithm Hash digest
SHA256 5613475a9afe02211066fce2a684dc50fa4f6f4ec5f05163f240f64a325a8043
MD5 250a4b1d6e24d5d4030f516347f75c6f
BLAKE2b-256 290e2c6cd1cd771a6cfa3460ecdf798bfe6bdefdc8d0c984a0c2e368689c78e3

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp311-cp311-manylinux_2_27_x86_64.manylinux_2_28_x86_64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 c6b5ab380a7fd9e0cfb03d7c2e81b670fe98128f68c4cd5bb014f567d43735dd
MD5 7272c5cd4dd1fa090ca9a57b29ebf7f8
BLAKE2b-256 4d7daf1db306be8a8749c5cbb83956813e52bff89eaf2055b56dab8fd9342dae

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp311-cp311-manylinux_2_26_aarch64.manylinux_2_28_aarch64.whl:

Publisher: publish.yml on equinor/surfio

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

File details

Details for the file surfio-0.0.21-cp311-cp311-macosx_15_0_arm64.whl.

File metadata

File hashes

Hashes for surfio-0.0.21-cp311-cp311-macosx_15_0_arm64.whl
Algorithm Hash digest
SHA256 9dc2e830cbec43db530cc30fb7a27377273632aa002c46cba6d13312e6f3b6db
MD5 9d33ff433cf14dee5dc722db664cdefa
BLAKE2b-256 7c213b6d0ac51344df064faee5e06895567cbb1996144aaea6cd30ca01fc53f2

See more details on using hashes here.

Provenance

The following attestation bundles were made for surfio-0.0.21-cp311-cp311-macosx_15_0_arm64.whl:

Publisher: publish.yml on equinor/surfio

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