Skip to main content

Machine learning application for detecting liquid droplets in mixed-phase clouds using Doppler cloud radar spectra

Project description

VoodooNet CI PyPI version DOI

VoodooNet

Predicting liquid droplets in mixed-phase clouds beyond lidar attenuation using artificial neural nets and Doppler cloud radar spectra

VOODOO is a machine learning approach based convolutional neural networks (CNN) to relate Doppler spectra morphologies to the presence of (supercooled) liquid cloud droplets in mixed-phase clouds.

Installation

Prerequisites

VoodooNet requires Python 3.10.

Before installing VoodooNet, install PyTorch according to your infrastructure. For example on a Linux machine without GPU you might run:

pip3 install torch --extra-index-url https://download.pytorch.org/whl/cpu

From PyPI

pip3 install voodoonet

Locally for development

pip3 install -e .[dev]

Usage

Make predictions using the default model and settings

import glob
import voodoonet

rpg_files = glob.glob('/path/to/rpg/files/*.LV0')
probability_liquid = voodoonet.infer(rpg_files)

Generate a training data set

Download some RPG-FMCW-94 raw files and corresponding classification files from the Cloudnet data portal API. For example, for Leipzig LIM between 2021-01-10 and 2021-01-15:

curl "https://cloudnet.fmi.fi/api/raw-files?dateFrom=2021-01-10&dateTo=2021-01-15&site=leipzig-lim&instrument=rpg-fmcw-94" | jq '.[]["downloadUrl"]' | xargs -n1 curl -O
curl "https://cloudnet.fmi.fi/api/files?dateFrom=2021-01-10&dateTo=2021-01-15&site=leipzig-lim&product=classification" | jq '.[]["downloadUrl"]' | xargs -n1 curl -O
import glob
import voodoonet

rpg_files = glob.glob('*.LV0')
classification_files = glob.glob('*classification.nc')
voodoonet.generate_training_data(rpg_files, classification_files, 'training-data-set.pt')

Alternatively, just use N random days:

import voodoonet
voodoonet.generate_training_data_for_cloudnet('leipzig-lim', 'training-data-set.pt', n_days=5)

Train a VoodooNet model

import voodoonet

pre_computed_training_data_set = 'training-data-set.pt'
voodoonet.train(pre_computed_training_data_set, 'trained-model.pt')

Make predictions using the new model

import glob
import voodoonet
from voodoonet.utils import VoodooOptions

rpg_files = glob.glob('/path/to/rpg/files/*.LV0')
options = VoodooOptions(trained_model='new_model.pt')
probability_liquid = voodoonet.infer(rpg_files, options=options)

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

voodoonet-0.1.10.tar.gz (10.5 MB view details)

Uploaded Source

Built Distribution

voodoonet-0.1.10-py3-none-any.whl (10.5 MB view details)

Uploaded Python 3

File details

Details for the file voodoonet-0.1.10.tar.gz.

File metadata

  • Download URL: voodoonet-0.1.10.tar.gz
  • Upload date:
  • Size: 10.5 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.3

File hashes

Hashes for voodoonet-0.1.10.tar.gz
Algorithm Hash digest
SHA256 e7fd422136aeff24b9b98a7000e6518b9c37ea688ba49f2ef9b9416a3fb7eecb
MD5 a5ca5a89ddf10017b947db06bb1b6c59
BLAKE2b-256 78283fbfa8f78255d90dea6add58667cc6eb158569bb1185ee41d0437f8b9790

See more details on using hashes here.

File details

Details for the file voodoonet-0.1.10-py3-none-any.whl.

File metadata

  • Download URL: voodoonet-0.1.10-py3-none-any.whl
  • Upload date:
  • Size: 10.5 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/5.0.0 CPython/3.12.3

File hashes

Hashes for voodoonet-0.1.10-py3-none-any.whl
Algorithm Hash digest
SHA256 d130b96493b6f063fb897cf5cfe8c9001cbde0f10ea26bd08d4226ebe8d9b076
MD5 6623d3449531274d0a2e9e143678c6e7
BLAKE2b-256 be6d4a4433704525ee9d2a74e87d09ec08bb4b3781755d4753a682a339ab9aeb

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page