Mantaray

A Rust Package for Ray Tracing Ocean Surface Gravity Waves.
https://github.com/mines-oceanography/mantaray

Category: Hydrosphere
Sub Category: Waves and Currents

Keywords

oceanography ray-tracing waves

Last synced: about 7 hours ago
JSON representation

Repository metadata

Mantaray: A Rust Package for Ray Tracing Ocean Surface Gravity Waves

README.md

PyPI version
Crates.io
DOI
License: MIT
License: Apache-2.0

Docs
Rust checks
Pixi Badge
Ruff

Ray Tracing

A library for surface gravity waves ray tracing.

Demo

Examples

The examples are located in the notebooks directory, and each scenario is inside its own subfolder.

To run the example notebooks, follow installation instructions to install pixi and clone the repo. Then, install the examples environment using pixi run -e examples develop.

After that there are multiple options:

  • Follow our development instructions for using jupyter lab.
  • Start a shell with the environment using the command pixi shell -e examples.
  • Find the installation inside the .pixi folder and run the examples your own way.

If there are additional instructions, such as needing data files, they will be located in the readme of that example's folder.

Development

Installation

  1. Install Pixi

  2. Fork Mantaray's repository, by clicking in the 'Fork' button in the top-right corner.

  3. Clone your forked repository. Check the green button and choose a protocol.
    For instance, if you use SSH you'll see something similar to:

git clone git@github.com:<your-username>/mantaray.git
cd mantaray
  1. Build Python
pixi run develop

This can take a few minutes the very first time.

Usage

At the top of your python file, you will need to include the following import line:

from mantaray.core import single_ray, ray_tracing

Documentation for these functions are located in core.py.

Run Python file

pixi run python path_to_file.py

Using Jupyter Lab

  1. Develop the code for the examples environment
pixi run -e examples develop
  1. Open Jupyter Lab using the examples environment
pixi run -e examples jupyter lab

To test Python library run:

pixi run -e test pytest

License

Licensed under either of

at your option.

Contribution

Unless you explicitly state otherwise, any contribution intentionally submitted
for inclusion in the work by you, as defined in the Apache-2.0 license, shall be
dual licensed as above, without any additional terms or conditions.

We welcome contributions to this project! Whether you're fixing a bug, adding a new feature, or improving the documentation, your help is greatly appreciated. All contributions should be made through GitHub, by forking the repository, creating a new branch, and submitting a pull request.

Ways to Contribute

There are many ways to contribute to this project, including:

  • Reporting bugs: If you find a bug, please open an issue and provide as much detail as possible, including steps to reproduce the issue.
  • Suggesting features: Have an idea for a new feature or improvement? Open an issue and describe your suggestion.
  • Submitting code changes: We welcome code contributions! If your change is based on an existing issue, please comment on that issue and let us know you are working on it. Otherwise, if it is something new, create an issue and let us know what you are working on. When ready to submit, please follow the Pull Request Guidelines below.
  • Improving documentation: Clear and concise documentation is essential. If you find areas where the documentation can be improved, please submit an issue.

When you create an issue, we may label it (bug, enhancement, etc). If we are unsure about what you are requesting, we will ask to clarify, and if you believe another label fits it better, let us know.

Pull Request Guidelines

Before submitting a pull request, please make sure it meets these guidelines:

  1. Tests: All pull requests should include unit tests that cover the changes.
  2. Documentation: If your pull request adds or modifies functionality, please update the documentation accordingly.
  3. CI: Your pull request must pass all existing continuous integration checks.
  4. Single Functionality: Each pull request should ideally address a single, well-defined functionality. If your changes are more extensive, please consider breaking them down into multiple, smaller pull requests.

Getting Help

If you have questions or need help getting started, please open an issue and ask. We'll do our best to assist you.

Citation (CITATION.cff)

cff-version: 1.2.0
title: >-
  Mantaray: A Rust Package for Ray Tracing Ocean Surface
  Gravity Waves
message: >-
  If you use this software, please cite it using the
  metadata from this file.
type: software
authors:
  - given-names: Bryce
    family-names: Irving
    affiliation: Colorado School of Mines
    orcid: 'https://orcid.org/0009-0004-2309-9522'
  - given-names: Guilherme
    family-names: Castelao
    affiliation: National Renewable Energy Laboratory
    orcid: 'https://orcid.org/0000-0002-6765-0708'
  - given-names: Colin
    family-names: Beyers
    affiliation: Colorado School of Mines
    orcid: 'https://orcid.org/0009-0004-8312-6158'
  - given-names: James
    family-names: Clemson
    affiliation: Colorado School of Mines
    orcid: 'https://orcid.org/0009-0000-4329-6575'
  - given-names: Jackson
    family-names: Krieger
    affiliation: Colorado School of Mines
    orcid: 'https://orcid.org/0009-0006-3693-8887'
  - given-names: Gwendal
    family-names: Marechal
    affiliation: Colorado School of Mines
    orcid: 'https://orcid.org/0000-0003-0378-5694'
  - given-names: Nicholas
    family-names: Pizzo
    affiliation: >-
      Graduate School of Oceanography, University of Rhode
      Island
    orcid: 'https://orcid.org/0000-0001-9570-4200'
  - given-names: Bia
    family-names: Villas Bôas
    affiliation: Colorado School of Mines
    orcid: 'https://orcid.org/0000-0001-6767-6556'
repository-code: 'https://github.com/mines-oceanography/mantaray'
url: 'https://github.com/mines-oceanography/mantaray'
keywords:
  - ray tracing
  - waves
  - oceanography
license: Apache-2.0
version: 0.3.0
date-released: '2025-12-01'

Owner metadata


GitHub Events

Total
Last Year

Committers metadata

Last synced: 27 days ago

Total Commits: 153
Total Committers: 8
Avg Commits per committer: 19.125
Development Distribution Score (DDS): 0.595

Commits in past year: 84
Committers in past year: 8
Avg Commits per committer in past year: 10.5
Development Distribution Score (DDS) in past year: 0.595

Name Email Commits
brycemines 1****s 62
Guilherme Castelão g****e@c****t 52
Bia Villas Boas v****s@m****u 21
dependabot[bot] 4****] 12
James Clemson 1****n 2
Colin Beyers 1****s 2
Paul Pinchuk p****k@n****v 1
Gwendal MARECHAL 1****l 1

Committer domains:


Issue and Pull Request metadata

Last synced: 14 days ago

Total issues: 14
Total pull requests: 43
Average time to close issues: about 2 months
Average time to close pull requests: 13 days
Total issue authors: 5
Total pull request authors: 8
Average comments per issue: 0.64
Average comments per pull request: 0.33
Merged pull request: 32
Bot issues: 0
Bot pull requests: 7

Past year issues: 14
Past year pull requests: 43
Past year average time to close issues: about 2 months
Past year average time to close pull requests: 13 days
Past year issue authors: 5
Past year pull request authors: 8
Past year average comments per issue: 0.64
Past year average comments per pull request: 0.33
Past year merged pull request: 32
Past year bot issues: 0
Past year bot pull requests: 7

More stats: https://issues.ecosyste.ms/repositories/lookup?url=https://github.com/mines-oceanography/mantaray

Top Issue Authors

  • brycemines (7)
  • milancurcic (3)
  • Sbozzolo (2)
  • biavillasboas (1)
  • castelao (1)

Top Pull Request Authors

  • castelao (19)
  • biavillasboas (10)
  • dependabot[bot] (7)
  • brycemines (3)
  • ppinchuk (1)
  • gmarechal (1)
  • jmclemson (1)
  • colinbeyers (1)

Top Issue Labels

  • bug (3)
  • enhancement (2)
  • documentation (2)

Top Pull Request Labels

  • github_actions (8)
  • dependencies (7)
  • enhancement (1)
  • documentation (1)
  • bugfix (1)

Package metadata

pypi.org: mantaray

Tracing rays

  • Homepage: https://github.com/mines-oceanography/mantaray
  • Documentation: https://mantaray.readthedocs.io/
  • Licenses: apache-2.0
  • Latest release: 0.3.0 (published 3 months ago)
  • Last Synced: 2026-02-16T09:01:31.876Z (3 days ago)
  • Versions: 5
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 983 Last month
  • Rankings:
    • Dependent packages count: 10.794%
    • Average: 35.791%
    • Dependent repos count: 60.788%
  • Maintainers (1)
crates.io: mantaray

Ray-tracing solver for ocean surface gravity waves that integrates the wave ray equations over spatially varying currents and bathymetry.

  • Homepage: https://github.com/mines-oceanography/mantaray
  • Documentation: https://docs.rs/mantaray/
  • Licenses: MIT OR Apache-2.0
  • Latest release: 0.2.0 (published 3 months ago)
  • Last Synced: 2026-02-16T09:01:31.883Z (3 days ago)
  • Versions: 3
  • Dependent Packages: 0
  • Dependent Repositories: 0
  • Downloads: 1,924 Total
  • Rankings:
    • Dependent repos count: 27.088%
    • Dependent packages count: 35.923%
    • Average: 53.172%
    • Downloads: 96.506%
  • Maintainers (2)

Dependencies

.github/workflows/ci.yml actions
  • Swatinem/rust-cache v2 composite
  • actions-rs/cargo v1 composite
  • actions-rs/toolchain v1 composite
  • actions/checkout v4 composite
  • prefix-dev/setup-pixi v0.8.8 composite
.github/workflows/python-doc.yml actions
  • Swatinem/rust-cache v2 composite
  • actions/checkout v4 composite
  • prefix-dev/setup-pixi v0.8.8 composite
.github/workflows/python-test.yml actions
  • Swatinem/rust-cache v2 composite
  • actions/checkout v4 composite
  • chartboost/ruff-action v1 composite
  • prefix-dev/setup-pixi v0.8.8 composite
Cargo.lock cargo
  • 151 dependencies
Cargo.toml cargo
  • lockfile 0.4.0 development
  • tempfile 3.19.1 development
  • derive_builder 0.20.0
  • libc 0.2.172
  • ndarray 0.16.1
  • netcdf 0.11.0
  • netcdf3 0.5.2
  • ode_solvers 0.4.0
  • pyo3 0.24.2
  • rayon 1.10.0
  • serde 1.0
  • serde_json 1.0.119
  • thiserror 2.0.12
  • tracing 0.1.41
docs/requirements.txt pypi
  • furo >=2023.09.10
  • myst-parser *
  • myst-sphinx-gallery *
  • nbconvert *
  • pandoc *
  • sphinx-copybutton *
  • sphinx-design *
  • sphinx-inline-tabs *
  • sphinx-tabs *
  • sphinxcontrib-mermaid *
pyproject.toml pypi
  • cffi >=1.14.0
  • xarray >=2023
.github/workflows/draft-pdf.yml actions
  • actions/checkout v4 composite
  • actions/upload-artifact v4 composite
  • openjournals/openjournals-draft-action master composite

Score: 14.080701592580523