Skip to main content

A package for l2 wind direction

Project description

l2 wind direction: README

This repository provides tools for predicting wind direction and estimating uncertainty from SAR images acquired by Sentinel-1 (S1), RADARSAT Constellation Mission (RCM), and RADARSAT-2 (RS2) satellites. It utilizes a trained machine learning model built with PyTorch Lightning and Hydra-Zen

Features

  • Prediction Pipeline: Load trained models and make predictions on new data.

  • Hydra-Zen Integration: Flexible configuration management.

  • Output Options: Generate predictions as a pandas DataFrame or an xarray Dataset.

  • Uncertainty Estimation: Predict both wind direction and associated uncertainty.

  • Georeferencing Support: Adjust predictions for geographical reference using dataset metadata.

Installation

Clone the repository:

git clone https://github.com/jean2262/l2winddir.git
cd l2winddir

Usage

Command-Line Interface

Run predictions using the predict.py script:

python predict.py --model_path <path_to_model> --data_path <path_to_data> --eval <True/False>
  • Arguments:

    • --model_path: Path to the trained model's directory.

    • --data_path: Path to the data file (NetCDF or xarray-compatible format).

    • --eval: If True, outputs a pandas DataFrame; otherwise, modifies and returns the input xarray Dataset.

Example

Command-Line

python predict.py --model_path "/path/to/model" --data_path "/path/to/dataset.nc" --eval True

Programmatic Usage

You can use the make_prediction function directly in Python scripts:

from predict import make_prediction

model_path = "/path/to/model"
data_path = "/path/to/dataset.nc"
result = make_prediction(model_path=model_path, data_path=data_path, eval=True)

print(result)

License

This project is licensed under the MIT License. See the LICENSE file for details.

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

l2winddir-0.0.3.tar.gz (11.7 kB view details)

Uploaded Source

Built Distribution

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

l2winddir-0.0.3-py3-none-any.whl (12.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: l2winddir-0.0.3.tar.gz
  • Upload date:
  • Size: 11.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for l2winddir-0.0.3.tar.gz
Algorithm Hash digest
SHA256 5f4fe7e09aab1292bd7a700d2e9f8a54d7003fc545de23a9b7cc68d9891b2d47
MD5 f5f71b4b87c19c57413fc6ec1ad33dff
BLAKE2b-256 72c09968c3d00050794e175644a2cb322137ff79c17875265bc41fc91b12dc03

See more details on using hashes here.

Provenance

The following attestation bundles were made for l2winddir-0.0.3.tar.gz:

Publisher: release.yaml on jean2262/l2winddir

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

File details

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

File metadata

  • Download URL: l2winddir-0.0.3-py3-none-any.whl
  • Upload date:
  • Size: 12.3 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.0.1 CPython/3.12.8

File hashes

Hashes for l2winddir-0.0.3-py3-none-any.whl
Algorithm Hash digest
SHA256 aab6d397ef625927be8d9ea8f0148d1d3281376328073714db69811134bbdf58
MD5 40d34d50bfb9e0ce224d29491bd69095
BLAKE2b-256 734c70f1609b28b095c1fed59265111f0febacda5612260c6c533a8ce508988f

See more details on using hashes here.

Provenance

The following attestation bundles were made for l2winddir-0.0.3-py3-none-any.whl:

Publisher: release.yaml on jean2262/l2winddir

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