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.1.tar.gz (11.6 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.1-py3-none-any.whl (12.3 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: l2winddir-0.0.1.tar.gz
  • Upload date:
  • Size: 11.6 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.1.tar.gz
Algorithm Hash digest
SHA256 39818a09aaf1579b82d17ff03da6bd9be9d536bfb0cc101395a627641694c376
MD5 067bc620faec3310fd52c14fba3f956c
BLAKE2b-256 4b19631a5497bc011e68d93f894fc10d92cd04467e9e161c8731b32cab5cb0e6

See more details on using hashes here.

Provenance

The following attestation bundles were made for l2winddir-0.0.1.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.1-py3-none-any.whl.

File metadata

  • Download URL: l2winddir-0.0.1-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.1-py3-none-any.whl
Algorithm Hash digest
SHA256 888cfebcbe33d1f40f43dd33fa73c0254299e3965b20e7d13070aec673a3241d
MD5 0672ecf1f1e0b57aae07af219ed27e36
BLAKE2b-256 589f76fbee769891f379e011d918ff5724e433be7dd64e3f3f17bbd2105fe1d2

See more details on using hashes here.

Provenance

The following attestation bundles were made for l2winddir-0.0.1-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