# Deep Learning
## Local short-term precipitation prediction through machine learning
```Thomas Gnädig, Etienne Gramlich, Tim Hardenacke, Merle Wolff and Oliver Dürr```
#### Abstract
We try to predict precipitation for a range of 35 minutes in an area around Constance.
Therefore we are using machine learning techniques and train a UNet on radar data images.
Here we present the result of precipitation prediction as well with regression as with classification.
Both approaches provide good results.
#### Data
We are using radar Data from the [Climate Data Center of the DWD](https://www.dwd.de/DE/klimaumwelt/cdc/cdc_node.html). Here are radarimages since 2004.
This data has to be Downloaded and converted to png this is done by our [Crawler](https://github.com/thgnaedi/DeepRain/tree/master/DWD_Crawler) and [Converter](https://github.com/thgnaedi/DeepRain/blob/master/Data/DWDtoPngScript.py).
The rainfall images then are tailored and scaled. resulting unattraktiv images are then rejected that only interessting images are used for the training.
The images are grayscales png's as Network input five temporally consecutive of them are combined to a 3D Tensor as input. The Label consits of seven of them.
#### Architecture
To predict precipitation either with regression or classification we are using a UNet.
This Architecture is a convolutional neural network that was at first developed for biomedical image segmentation.
A UNet is a set of convulution layers, combined with an downlampling part, such as pooling Layers, and later with upsampling parts like deconvolution layers.
![Image of an UNet](https://github.com/thgnaedi/DeepRain/blob/master/Docs/pics/UNet_Biomedical.PNG)
The image is taken from the [university of freiburg](https://lmb.informatik.uni-freiburg.de/people/ronneber/u-net/)
The input images have a shape of 64x64 pixels. They are pooled until the shape reaches a minimum of 8x8 features. Then they are upsampled and concatenated with the downsampling part.
This yields into an u-shaped architecture with crosslinks and is the reason for its Name.
#### Regression
First approache is to predict the complete radar image. For this regression we use the MSE as lossfunction. The input layer takes the five incoming timesteps and transfer it into a 7 timestep prediction wich reaches up to 35 minutes into the future.
Our network is trained on the radar data from 2005 till 2017. As validation set we use the images from 2004. further information can be found in our full project description PDF TODO: LINK
The result of this task is shown in the following graphics.
The input is a 64x64x5 Tesnor, containing the last 25 minutes, with the following content:
![input date](https://github.com/thgnaedi/DeepRain/blob/master/Docs/pics/dt5.png)
The Labels are seven timesteps to predict, from 5 minutes till 35 minutes into the future. The result is shown here:
![labels and output](https://github.com/thgnaedi/DeepRain/blob/master/Docs/pics/t5.png)
In the upper row we can see the seven timesteps in the Labels. White means a lot rainfall while black is no rainfall.
the second row contains the labels for this input. In the last row are the predictions of our model.
The predicted values are verry close to the label for a difference of only 5 minutes to the input data. the further the time progresses, the worse the prediction becomes.
In the last image it looks like the resolution of the output has been drastically decreased compared to the first output.
In fact the resolution is the same we can say that this is an indication of uncertainty in the Network.
Over the time, the movement of the rainfall is well predicted. even the tiny spot in the top left of Images can be predicted.
Even if the area of rainfall increases much faster than in the labels, the center is still well predicted and close to the center of the label.
#### Classification
The second approach is to predict the precipitation by classification. Here we try to classify into either three classes (no rain, rain, heavy rain) or two classes (no rain, rain) for each pixel.
Herefor the Unets output is modified to three classes per pixel and an additional softmax layer at the output to provide propabilities. The labels are generated by a threshold for each class and the predictionimage after 35 minutes.
to show the output of the pixelwise classification the class heavy rainfall has been plotted to the following image.
![classification output](https://github.com/thgnaedi/DeepRain/blob/master/Docs/pics/categorical_crossentropy_hidden-softmax_output-softmax_above_3072.png)
in the left image the prediction of the first class (no rainfall) is plotted. the white spots are 100% no rainfall. the black spots are 0% no rainfall.
the gray spots can be rainfall or not depending on the propabilitiey of the other two classes. The right image (difference) shows us the absolute difference between the prediction and the label.
Here we can see that the big black spots (no difference between prediction and label) are at the no rainfall labels. This can be explained later.
The network has a high accuracy by predicting rainfree pixels. this can be shown in the follwing ROC-image.
By evaluating the confusion matrix for three class classification, you can recognize that the last class (heavy rainfall) is higly undersampled.
There are much more rainfall pixels and even more no rainfall pixels in the Dataset. To increase the the performance we tried over and undersampling, but both tecniques didnt work well for our scenario.
Finally we changed the problem to a two clas classification with a threshold of 0, so the classes are 'no rainfall' and 'rainfall'.
To show the performance you can take a lock at the ROC. The calculated AUC is close to 96%, wich means, that the model has a good class separation.
![ROC](https://github.com/thgnaedi/DeepRain/blob/master/Docs/pics/ROC-curve.png)
#### Conclusion and Future Work
In summary, this paper argued that short term precipitation prediction can be done by only observing radar data and without any other source of information.
The accuracy could still be imporved as well at the regression, were another lossfunction may could help, as at the classification were the rainfall class is still undersampled and worse accurate than the 'no rain' class.
没有合适的资源?快使用搜索试试~ 我知道了~
DeepRain:使用 UNet 进行短期降水预测
共192个文件
png:42个
h5:29个
py:29个
需积分: 44 20 下载量 20 浏览量
2021-05-29
15:35:44
上传
评论 4
收藏 96.52MB ZIP 举报
温馨提示
深雨 该项目是在 HTWG Konstanz - 应用科学大学的课程背景下创建的。 目标是使用机器学习对康斯坦茨周边地区 35 分钟的短期降水预测。 因此,我们在 keras 和 tensorflow 中为 python 3 使用了 UNet 实现。 我们的团队: 、 、 、 在教授的监督下使用 UNet 创建了短期降水预测。 结果 可以从我们的英文论文中阅读 或在我们完整德语报告中 要求 要运行此存储库中的脚本,您需要 Python 发行版并另外安装以下软件包: 凯拉斯 张量流 cv2 (OpenCV) 拉德利卜
资源推荐
资源详情
资源评论
收起资源包目录
DeepRain:使用 UNet 进行短期降水预测 (192个子文件)
report.bib 12KB
htwg-report.cls 18KB
Directory 1B
docs 10B
M_black.eps 1021KB
B_black.eps 998KB
S_black.eps 992KB
C_black.eps 987KB
.gitignore 3KB
.gitignore 457B
CNN_deeper_17epoch_25k.h5 202KB
CNN_deeper_1epoch_25k.h5 202KB
CNN_deeper_3epoch_25k.h5 202KB
CNN_deeper_14epoch_25k.h5 202KB
CNN_deeper_13epoch_25k.h5 202KB
CNN_deeper_18epoch_25k.h5 202KB
CNN_deeper_10epoch_25k.h5 202KB
CNN_deeper_12epoch_25k.h5 202KB
CNN_deeper_20epoch_25k.h5 202KB
CNN_deeper_8epoch_25k.h5 202KB
CNN_deeper_19epoch_25k.h5 202KB
CNN_deeper_4epoch_25k.h5 202KB
CNN_deeper_11epoch_25k.h5 202KB
CNN_deeper_7epoch_25k.h5 202KB
CNN_deeper_5epoch_25k.h5 202KB
CNN_deeper_16epoch_25k.h5 202KB
CNN_deeper_9epoch_25k.h5 202KB
CNN_deeper_6epoch_25k.h5 202KB
CNN_deeper_2epoch_25k.h5 202KB
CNN_deeper_15epoch_25k.h5 202KB
categorical_crossentropy_hidden-softmax_output-softmax_above_1536.h5 180KB
categorical_crossentropy_hidden-softmax_output-softmax_above_1536.h5 180KB
categorical_crossentropy_hidden-softmax_output-softmax_above_1536.h5 180KB
categorical_crossentropy_hidden-softmax_output-softmax_above_1536.h5 180KB
categorical_crossentropy_hidden-softmax_output-softmax_above_1536.h5 180KB
categorical_crossentropy_hidden-softmax_output-softmax_above_1536.h5 180KB
categorical_crossentropy_hidden-softmax_output-softmax_above_1536.h5 180KB
categorical_crossentropy_hidden-softmax_output-softmax_above_1536.h5 180KB
data.h5 800B
DWDtoPng.ipynb 2.45MB
StarteDWD_to_PNG.ipynb 181KB
Anwendung simple_image_script.ipynb 41KB
DeepRain_WRADLIB.ipynb 28KB
simple_U-Net.ipynb 27KB
Data Analysis.ipynb 24KB
ROC.ipynb 23KB
png_to_numpy.ipynb 15KB
Large Histogram Calculator.ipynb 12KB
MNIST_Example_keras.ipynb 9KB
Fehlerfunktion_Trainieren_bsp.ipynb 5KB
Untitled.ipynb 3KB
Regenradar_Historisch.JPG 149KB
result.JPG 114KB
ANN_for_deep_learning_P35.JPG 88KB
result_2017.JPG 82KB
LICENSE 1KB
trainphase.log 262KB
trainphase.log 262KB
trainphase.log 262KB
trainphase.log 262KB
trainphase.log 262KB
trainphase.log 262KB
trainphase.log 262KB
trainphase.log 262KB
makefile 674B
README.md 6KB
README.md 5KB
README.md 2KB
Readme.md 1KB
snipet.md 1KB
README.md 1KB
Readme.md 947B
README.md 567B
README.md 520B
README.md 235B
Auswertung.ods 22KB
Langdokumentation.pdf 1.47MB
report.pdf 397KB
report_cover_empty.pdf 206KB
ROC-classes.pdf 31KB
report_titel_page.pdf 29KB
ROC-curve.pdf 12KB
Map_Overlay.png 356KB
RZ_product.PNG 200KB
scaled_1707251910_LinearWithClipping.png 158KB
vgl_lc_optim.png 127KB
mse_vgl1.png 114KB
roc.PNG 108KB
06_CNN_deeper_2epoch_10k_SCALED.png 96KB
06_CNN_deeper_2epoch_10k.png 91KB
lc_35minMSE.png 91KB
03_CNN_simple_5x5_5x5_2epoch.png 90KB
01_CNN_simple.png 88KB
04_CNN_simple_5x5_5x5_4epoch.png 86KB
02_CNN_deeper_2epoch.png 84KB
35min_vgl_zeros.png 79KB
35min_vgl_baseline.png 78KB
t2.png 69KB
raa01-rw_10000-0506301650-dwd---bin.gz.png 65KB
Syntetische_Daten_CNN_UNet.png 63KB
共 192 条
- 1
- 2
资源评论
NinglingPan
- 粉丝: 19
- 资源: 4645
上传资源 快速赚钱
- 我的内容管理 展开
- 我的资源 快来上传第一个资源
- 我的收益 登录查看自己的收益
- 我的积分 登录查看自己的积分
- 我的C币 登录后查看C币余额
- 我的收藏
- 我的下载
- 下载帮助
最新资源
- 3122080306 邹子轩 实验报告二.docx
- 基于STM32 NUCLEO板设计彩色LED照明灯(纯cubeMX开发)(大赛作品,文档完整,可直接运行)
- 发那科工业机器人保养大全
- Sphere.h
- REMD固有时间尺度分解信号分量可视化(Matlab完整源码和数据)
- 嵌入式系统双单片机STC89C52+STC15W104多功能学习板电路图可扩展 适用于单片机初学者和教学
- 基于STM32蓝牙控制小车系统设计(硬件+源代码+论文)大赛作品
- XILINXFPGA源码基于Spartan3火龙刀系列FPGA开发板VGA测试例程
- Java聊天室的设计与实现【尚学堂·百战程序员】
- python中matplotlib教程
资源上传下载、课程学习等过程中有任何疑问或建议,欢迎提出宝贵意见哦~我们会及时处理!
点击此处反馈
安全验证
文档复制为VIP权益,开通VIP直接复制
信息提交成功