Skip to main content

A personal reimplementation of NowcastNet inference framework

Project description

NowcastNet-Rewritten

1. Introduction

This project is a personal reimplementation of the NowcastNet inference framework. The original research, titled "Skilful nowcasting of extreme precipitation with NowcastNet," by Yuchen Zhang, Mingsheng Long et al., was published in Nature and can be accessed at https://www.nature.com/articles/s41586-023-06184-4. Additionally, the original code by Yuchen Zhang is available at https://doi.org/10.24433/CO.0832447.v1.

Q: Why reimplement? A: Just for learning :)

2. Getting Started

  1. Cloning the repository:

    git clone https://github.com/VioletsOleander/nowcastnet-rewritten.git
    
  2. Install the package from PyPI:

    pip install -U nowcastnet-rewritten
    

Notes:

  • You may need to implement your own code to read the dataset. Sample code for reading the radar dataset is provided in the datasets directory.
  • To ensure compatibility with this reimplementation's architecture, weights have been modified and are available for download from Hugging Face.

3. Usage

To start inference, run inference.py with required arguments.

To get an overview of the arguments, start with the basic command:

python inference.py -h

Here is an example shell script do_inference.sh to streamline the process. You can adjust it accordingly:

#!/bin/bash
python inference.py \
    --case_type normal \
    --device cuda:0 \
    "path_to_weights" \
    "path_to_data" \
    "path_to_result" \

4. Example Inference Result

1024 x 1024:

Inference output at 1024×1024 resolution

512 x 512:

Inference output at 512x512 resolution

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

nowcastnet_rewritten-0.0.2.tar.gz (15.1 kB view details)

Uploaded Source

Built Distribution

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

nowcastnet_rewritten-0.0.2-py3-none-any.whl (20.2 kB view details)

Uploaded Python 3

File details

Details for the file nowcastnet_rewritten-0.0.2.tar.gz.

File metadata

  • Download URL: nowcastnet_rewritten-0.0.2.tar.gz
  • Upload date:
  • Size: 15.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.10.16

File hashes

Hashes for nowcastnet_rewritten-0.0.2.tar.gz
Algorithm Hash digest
SHA256 339de175c46791688728d07dec3b4c78d1440e3c989902db91efa415d9e741d6
MD5 31a2cdda444f2ec05bc5643d87c9d5cb
BLAKE2b-256 33fef7272e931bd60a40f8f7f5d3a6630b29a8d2e15ab4453a159f593670da35

See more details on using hashes here.

File details

Details for the file nowcastnet_rewritten-0.0.2-py3-none-any.whl.

File metadata

File hashes

Hashes for nowcastnet_rewritten-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 9c765069b65e809b9b281623dc4cbc4a6fb23c212b3d181c9e9577dd0d1757e1
MD5 a843549235a4948a79e91a1a07a59223
BLAKE2b-256 4f9bd60f4b205aab02ee5e68e5527a0d9513915f493db62aa649fcdc303c2502

See more details on using hashes here.

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