SYNTOLOGY HomeExplorerAtlasCodeMethodologyAboutDevelopersFeedPricing
Paper · 2211.16824 · NeurIPS · 2022

WeatherFusionNet: Predicting Precipitation from Satellite Data

Jiří Pihrt, Rudolf Raevskiy, Petr Šimánek, Matej Choma, Meteopress Spol

arXiv · PDF · Open in the Atlas

Code that ran

9 of 12 samples (functions and classes) lifted from this paper's linked repositories executed on a synthesized input in Syntology's jail (0 of them constructed an object rather than computing a result; 0 honoured the contract we drafted, 0 violated it and 5 have no contract verdict; 4 failures of our instrument; 3 no recorded run), measured 2026-11-23; repository links from the Papers with Code archive attributed under CC BY-SA, no affiliation; bodies inline only under a permissive licence as GitHub detects it. Not a reproduction of the paper's results.

"Ran" means the function executed on a synthesized input and returned a value. It is not a reproduction of the paper's results. This record, dated, as JSON: /api/ran/2211.16824.json · badge: /api/ran/2211.16824.svg

Each repository's role is a label: a classifier's output recorded on the link, or, where no role is recorded, what the Papers with Code archive marked. The line under it names its basis. Neither says who wrote the code.

RepositoryRoleRan
datalab-fit-ctu/weather4cast-2022 reimplementation (classifier label)
classifier basis: classifier_2025
8 ran · 3 no recorded run
copy not recorded community
not in the paper's declared repositories
1 ran · 0 no recorded run
FunctionStatusWhere it lives
DiceBCELoss Ran
ran on a synthesized input
datalab-fit-ctu/weather4cast-2022/models/models.py
code served (permissive licence) · get_code("5965b29075d60b2f")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, class construct-then-call prompt, model not recorded) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn
import torch.nn.functional as F

class DiceBCELoss(nn.Module):

    def __init__(self, weight=None, size_average=True):
        super(DiceBCELoss, self).__init__()

    def forward(self, inputs, targets, smooth=1):
        inputs = F.sigmoid(inputs)
        inputs = inputs.view(-1)
        targets = targets.view(-1)
        intersection = (inputs * targets).sum()
        dice_loss = 1 - (2.0 * intersection + smooth) / (inputs.sum() + targets.sum() + smooth)
        BCE = F.binary_cross_entropy(inputs, targets, reduction='mean')
        Dice_BCE = BCE + dice_loss
        return Dice_BCE


INIT_ARGS = {
    'weight': None,
    'size_average': True
}

ARGS = {
    'inputs': torch.randn(2, 4),
    'targets': torch.randint(0, 2, (2, 4)).float(),
    'smooth': 1
}

if __name__ == '__main__':
    loss_fn = DiceBCELoss(**INIT_ARGS)
    output = loss_fn(**ARGS)
    print(f"Loss output: {output}")
    print(f"Output shape: {output.shape}")
    print(f"Output type: {type(output)}")
Setup block drafted by
a language model, class construct-then-call prompt, model not recorded
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: torch and numpy seeded to 0 by the harness immediately before the class was constructed from INIT_ARGS (fixture_check.py)
DiceLoss Ran
ran on a synthesized input
datalab-fit-ctu/weather4cast-2022/models/models.py
code served (permissive licence) · get_code("77dc311db139f25b")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, class construct-then-call prompt, model not recorded) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

class DiceLoss(nn.Module):

    def __init__(self, weight=None, size_average=True):
        super(DiceLoss, self).__init__()

    def forward(self, targets, inputs, smooth=1):
        import torch.nn.functional as F
        inputs = F.sigmoid(inputs)
        inputs = inputs.view(-1)
        targets = targets.view(-1)
        intersection = (inputs * targets).sum()
        dice = (2.0 * intersection + smooth) / (inputs.sum() + targets.sum() + smooth)
        return 1 - dice


INIT_ARGS = {
    'weight': None,
    'size_average': True
}

ARGS = {
    'targets': torch.randint(0, 2, (2, 4), dtype=torch.float32),
    'inputs': torch.randn(2, 4),
    'smooth': 1
}

if __name__ == '__main__':
    model = DiceLoss(**INIT_ARGS)
    output = model(**ARGS)
    print(f"Output: {output}")
    print(f"Output shape: {output.shape}")
Setup block drafted by
a language model, class construct-then-call prompt, model not recorded
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: torch and numpy seeded to 0 by the harness immediately before the class was constructed from INIT_ARGS (fixture_check.py)
FocalLoss Ran
ran on a synthesized input
datalab-fit-ctu/weather4cast-2022/models/models.py
code served (permissive licence) · get_code("3fb74cc402784e70")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, class construct-then-call prompt, model not recorded) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

class FocalLoss(nn.Module):

    def __init__(self, pos_weight=None, size_average=True):
        super(FocalLoss, self).__init__()
        self.bce = nn.BCEWithLogitsLoss(pos_weight=pos_weight)

    def forward(self, inputs, targets, alpha=2, gamma=0.8):
        bce = self.bce(inputs, targets)
        bce_exp = torch.exp(-bce)
        focal_loss = alpha * (1 - bce_exp) ** gamma * bce
        return focal_loss


INIT_ARGS = {
    'pos_weight': None,
    'size_average': True,
}

ARGS = {
    'inputs': torch.randn(2, 4),
    'targets': torch.randint(0, 2, (2, 4)).float(),
    'alpha': 2,
    'gamma': 0.8,
}

if __name__ == '__main__':
    model = FocalLoss(**INIT_ARGS)
    output = model(**ARGS)
    print(f"Output shape: {output.shape}")
    print(f"Output: {output}")
Setup block drafted by
a language model, class construct-then-call prompt, model not recorded
Imports
torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: torch and numpy seeded to 0 by the harness immediately before the class was constructed from INIT_ARGS (fixture_check.py)
PhyDNetWrapper Ran
ran on a synthesized input
datalab-fit-ctu/weather4cast-2022/models/models.py
code served (permissive licence) · get_code("92e77333d59e2dc4")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, class construct-then-call prompt, model not recorded) and returned Tensor, ndim 5, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import tempfile
import os
import yaml

# Create a minimal config file
config_dict = {
    'model': {
        'input_channels': 3,
        'hidden_channels': 8,
        'kernel_size': 3,
        'num_layers': 2,
        'input_length': 4,
        'output_length': 2,
    },
    'training': {
        'batch_size': 2,
    }
}

# Write config to a temporary file
temp_dir = tempfile.mkdtemp()
config_path = os.path.join(temp_dir, 'config.yaml')
with open(config_path, 'w') as f:
    yaml.dump(config_dict, f)

# Create a minimal PhyDNet class since it's imported
class PhyDNet(torch.nn.Module):
    def __init__(self, config):
        super().__init__()
        model_config = config['model']
        self.input_channels = model_config['input_channels']
        self.hidden_channels = model_config['hidden_channels']
        self.input_length = model_config['input_length']
        self.output_length = model_config['output_length']
        
        # Simple conv layer as stand-in
        self.conv = torch.nn.Conv2d(
            self.input_channels, 
            self.hidden_channels, 
            kernel_size=3, 
            padding=1
        )
        self.out_conv = torch.nn.Conv2d(
            self.hidden_channels,
            self.input_channels,
            kernel_size=3,
            padding=1
        )
    
    def forward(self, x):
        # x shape: (batch, time, channels, height, width)
        batch, time, c, h, w = x.shape
        # Process and return output sequence
        out = []
        for t in range(self.output_length):
            # Use last frame
            frame = x[:, -1]
            hidden = self.conv(frame)
            pred = self.out_conv(hidden)
            out.append(pred)
        return torch.stack(out, dim=1)

# Mock the import
import sys
from types import ModuleType

models_module = ModuleType('models')
backbones_module = ModuleType('backbones')
phydnet_module = ModuleType('phydnet')

phydnet_module.PhyDNet = PhyDNet
backbones_module.phydnet = phydnet_module
models_module.backbones = backbones_module

sys.modules['models'] = models_module
sys.modules['models.backbones'] = backbones_module
sys.modules['models.backbones.phydnet'] = phydnet_module

INIT_ARGS = {
    'config_path': config_path,
    'ckpt_path': None
}

ARGS = {
    'x': torch.randn(2, 4, 3, 16, 16)  # (batch, time, channels, height, width)
}
Setup block drafted by
a language model, class construct-then-call prompt, model not recorded
Imports
models, torch, yaml — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 5, dtype family float — no output shape is stated: observe_signature.py observed this class with its constructor sizes canonicalised where it could, which the node does not record, so its shape is not stated as this setup block's
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: torch and numpy seeded to 0 by the harness immediately before the class was constructed from INIT_ARGS (fixture_check.py)
UNetWrapper Ran
ran on a synthesized input
datalab-fit-ctu/weather4cast-2022/models/models.py
code served (permissive licence) · get_code("a82c5129db49750c")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, class construct-then-call prompt, model not recorded) and returned Tensor, ndim 5, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch
import torch.nn as nn

# Mock the UNet import since we can't access models.backbones.unet
class UNet(nn.Module):
    def __init__(self, input_channels, num_classes, nb_filter=None):
        super().__init__()
        if nb_filter is None:
            nb_filter = [16, 32, 64]
        self.input_channels = input_channels
        self.num_classes = num_classes
        # Simple mock UNet with conv layers
        self.enc1 = nn.Conv2d(input_channels, nb_filter[0], 3, padding=1)
        self.enc2 = nn.Conv2d(nb_filter[0], nb_filter[1], 3, padding=1)
        self.dec1 = nn.Conv2d(nb_filter[1], nb_filter[0], 3, padding=1)
        self.out = nn.Conv2d(nb_filter[0], num_classes, 3, padding=1)
    
    def forward(self, x):
        x = torch.relu(self.enc1(x))
        x = torch.relu(self.enc2(x))
        x = torch.relu(self.dec1(x))
        x = self.out(x)
        return x

# Patch the import
import sys
from types import ModuleType
models_module = ModuleType('models')
backbones_module = ModuleType('backbones')
unet_module = ModuleType('unet')
unet_module.UNet = UNet
backbones_module.unet = unet_module
models_module.backbones = backbones_module
sys.modules['models'] = models_module
sys.modules['models.backbones'] = backbones_module
sys.modules['models.backbones.unet'] = unet_module

class UNetWrapper(torch.nn.Module):

    def __init__(self, input_channels, output_channels, nb_filter=None):
        super().__init__()
        self.input_channels = input_channels
        from models.backbones.unet import UNet
        self.model = UNet(input_channels=input_channels, num_classes=output_channels, nb_filter=nb_filter)

    def forward(self, x):
        img_w = x.shape[-2]
        img_h = x.shape[-1]
        pw = (32 - img_w % 32) // 2
        ph = (32 - img_h % 32) // 2
        x = x.reshape(-1, self.input_channels, img_w, img_h)
        x = torch.nn.functional.pad(x, (pw, pw, ph, ph), mode='replicate')
        x = self.model(x)
        x = x.unsqueeze(1)
        x = x[..., pw:-pw, ph:-ph]
        return x


INIT_ARGS = {
    'input_channels': 3,
    'output_channels': 2,
    'nb_filter': [16, 32, 64]
}

ARGS = {
    'x': torch.randn(2, 3, 48, 64)
}

if __name__ == '__main__':
    model = UNetWrapper(**INIT_ARGS)
    output = model(**ARGS)
    print(f"Input shape: {ARGS['x'].shape}")
    print(f"Output shape: {output.shape}")
Setup block drafted by
a language model, class construct-then-call prompt, model not recorded
Imports
models, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 5, dtype family float — no output shape is stated: observe_signature.py observed this class with its constructor sizes canonicalised where it could, which the node does not record, so its shape is not stated as this setup block's
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: torch and numpy seeded to 0 by the harness immediately before the class was constructed from INIT_ARGS (fixture_check.py)
crop_slice Ran
ran; our contract draft was wrong, not the code
this paper's copy was not recorded; identical code first harvested from lxz1217/weather4cast-2023-lxz
pointer only; the stored copy get_code serves, from lxz1217/weather4cast-2023-lxz, is pointer only (licence: NONE) · get_code("16742794473930b0")
How it ran

The body of this sample is withheld: this paper's copy of the code was not recorded (its link names no repository or source path), so no licence was read for it. The setup block that called it is withheld with it, because it is written against that body. source_path and origin say where the code lives, to read under the repository's own terms. A run is recorded.

iou_class Ran
ran; our contract draft was wrong, not the code
datalab-fit-ctu/weather4cast-2022/utils/evaluate.py
code served (permissive licence) · get_code("1af147c7580eb38a")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned Tensor, ndim 0, dtype family float, shape () as a later run recorded it. The image it ran in was not recorded. If your copy returns the same type, ndim and shape on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch as t
import torch.nn as nn

t.manual_seed(0)

# Create small binary tensors for y_pred and y_true
# The function performs bitwise operations and sums over axes (0, 1, 2, 3, 4)
# So we need tensors with at least 5 dimensions
y_pred = t.randint(0, 2, (2, 2, 2, 2, 2), dtype=t.float32)
y_true = t.randint(0, 2, (2, 2, 2, 2, 2), dtype=t.float32)

ARGS = {
    "y_pred": y_pred,
    "y_true": y_true,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy, sklearn, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type Tensor, ndim 0, dtype family float, shape () — shape () as a later run recorded it
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
load_config Ran
ran; our contract draft was wrong, not the code
datalab-fit-ctu/weather4cast-2022/models/models.py
code served (permissive licence) · get_code("dfc63e975a513b62")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned dict. The image it ran in was not recorded. If your copy returns the same type on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import tempfile
import yaml
import os

# Create a temporary YAML configuration file
temp_dir = tempfile.mkdtemp()
config_file_path = os.path.join(temp_dir, "config.yaml")

# Write a sample configuration to the file
sample_config = {
    "model": "resnet50",
    "learning_rate": 0.001,
    "batch_size": 32,
    "epochs": 10,
    "layers": [64, 128, 256],
    "dropout": 0.5
}

with open(config_file_path, 'w') as f:
    yaml.dump(sample_config, f)

ARGS = {
    "config_path": config_file_path
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
yaml — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type dict — a dict output has no array shape of its own; none is stated — the instrument coerces any output to an array; for a dict output the recorded ndim 0 and dtype family float describe that coercion, not the output, and are not stated
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
recall_precision_f1_acc Ran
ran; our contract draft was wrong, not the code
datalab-fit-ctu/weather4cast-2022/utils/evaluate.py
code served (permissive licence) · get_code("1a1fd1c9e866a5db")
How it ran

Ran in Syntology's sandbox on this synthesized input (drafted by a language model, Claude Haiku 4.5, prompt python_fixture_v1) and returned tuple, ndim 1, dtype family float; no output shape is stated. The image it ran in was not recorded. If your copy returns the same type and ndim on these inputs, it matched what we observed; nothing here checks that. It does NOT mean the output is correct: nothing has compared it to the paper.

import torch as t
import numpy as np

t.manual_seed(0)

# Create small binary classification ground truth and predictions
# The function expects numpy arrays or torch tensors that can be converted to numpy
y_true = t.tensor([0, 1, 1, 0, 1, 0], dtype=t.long)
y_pred = t.tensor([0, 1, 0, 0, 1, 1], dtype=t.long)

ARGS = {
    "y": y_true,
    "y_hat": y_pred,
}
Setup block drafted by
a language model, Claude Haiku 4.5, prompt python_fixture_v1
Imports
numpy, sklearn, torch — import names as written, not package names to install; a name the repository itself provides is not a package
Returned
type tuple, ndim 1, dtype family float — a tuple output has no array shape of its own; none is stated
dtype family
int means an integer dtype; float means any other dtype the instrument saw, bool and complex included (fixture_check.py records only these two families)
Environment
image not recorded; re-verify against syntology-harvest-sandbox:v5-deps; not recorded for this sample: the harness installs a cuda-to-cpu shim (cuda_shim.py) before every sample and no run records whether a sample needed it; seed: none by the harness; any seed is in the setup block
BaseLitModule Not yet run
unverified (harvested, no recorded run)
datalab-fit-ctu/weather4cast-2022/models/models.py
code served (permissive licence) · get_code("544960851a619e16")
How it ran

no invocation recorded.

WeatherFusionNet Not yet run
unverified (harvested, no recorded run)
datalab-fit-ctu/weather4cast-2022/models/models.py
code served (permissive licence) · get_code("8a439c39fbfd78c8")
How it ran

no invocation recorded.

get_confusion_matrix Not yet run
unverified (harvested, no recorded run)
datalab-fit-ctu/weather4cast-2022/utils/evaluate.py
code served (permissive licence) · get_code("0c2bf7e7dc6299f5")
How it ran

no invocation recorded. this sample carries JSON test cases instead of a setup block; get_reference_implementation serves them with the level they back.

Also present in other papers' code

Of 12 samples lifted from this paper's linked repositories, 12 carry a function identity and 0 do not. Of the 12 distinct functions with an identity, 1 are also present in other papers whose code we hold (0 with at least one paper dated earlier, 0 the same month, 1 later) and 11 are only here among the 52,977 papers whose code Syntology holds (as of 2026-09-26).

Only here means: among the 52,977 papers whose code Syntology holds (51,887 with lifted samples, 1,090 through their assemblies only), as of 2026-09-26, no other paper's lifted samples or current assembly bricks contain an identical function body after normalisation.

FunctionAlso present inEarliest-datedOthers named
crop_slice
brick of this paper's assembly: helper
1 other paper
1 later
2401.09424 (2024-01)
Precipitation Prediction Using an Ensemble of Lightweight Learners

Presence, not direction: an identical function body in two papers' repositories does not say who wrote it, which came from which, or that either paper's method rests on it. Matching is exact after normalisation, so a renamed or edited function is not matched. Dates are when papers appeared, not when code was written. Only .py files the harvester lifted are covered; notebooks are not read. A new-style arXiv id YYMM.NNNN dates a paper to the month 20YY-MM; otherwise Paper.year dates it to the year; otherwise it is undated. Dates are when the paper appeared, not when the code was written. Read 2026-11-23.

Repositories linked to this paper

Some links come from the archived Papers with Code dataset (CC BY-SA 4.0): attribution and licence.

Abstract

The short-term prediction of precipitation is critical in many areas of life. Recently, a large body of work was devoted to forecasting radar reflectivity images. The radar images are available only in areas with ground weather radars. Thus, we aim to predict high-resolution precipitation from lower-resolution satellite radiance images. A neural network called WeatherFusionNet is employed to predict severe rain up to eight hours in advance. WeatherFusionNet is a U-Net architecture that fuses three different ways to process the satellite data; predicting future satellite frames, extracting rain information from the current frames, and using the input sequence directly. Using the presented method, we achieved 1st place in the NeurIPS 2022 Weather4cast Core challenge. The code and trained parameters are available at https://github.com/Datalab-FIT-CTU/weather4cast-2022.

For agents

The same record, over MCP at https://syntology.ai/mcp:

get_harvested_code_for_paper("2211.16824")
get_code_for_paper("2211.16824")
have("2211.16824")

The run record, dated, one paper per request, free:

curl https://syntology.ai/api/ran/2211.16824.json

A badge for a README (the split and the date, never a ratio):

[![Syntology run record](https://syntology.ai/api/ran/2211.16824.svg)](https://syntology.ai/paper/2211.16824)

Connect an agent — have() is free.