---
# System prepended metadata

title: Parsing FVM_GT4PY with the DaCe Python Frontend
tags: [betting-archive, dace]

---

# Parsing FVM_GT4PY with the DaCe Python Frontend  
###### tags: `betting-archive` `dace` 

In the past cycle, we have successfully written a DaCe-enabled version for the acoustic substep of `fv3core` and support for DaCe of elementary patterns of MPDATA have been introduced. 

These pattern are also used in the [FVM_GT4PY](https://github.com/ckuehnlein/FVM_GT4PY) implementation of the IFS-FVM model. The goal of this project is to use those building blocks and support additional patterns (operator class, reductions as well as storage views) to build an SDFG of this code in an automated manner. This will help to further harden the approach of using gt4py stencils with the dace python frontend, ensure that the user code will not diverge from a state that is ammenable to this approach, as well as enable wholistic program optimization in future cycles.

## Goals

* Creation of a DaCe enabled version of the elliptic solver in [FVM_GT4PY](https://github.com/ckuehnlein/FVM_GT4PY)
* [*optional*] Extension to the entire dycore

### No-Goals
* There is no focus on performance optimization in this project
* This project does not aim to create a generic Python-to-C++ compiler. While the approach generalizes to more applications, some restrictions apply. This is mostly equivalent to the restrictions imposed by using DaCe's `dace.program` decorators, which are documented in the DaCe framework. However, adding functionality to both DaCe and GT4Py are within the scope of the cycle.

## Concerns

- The current implementation has no proper validation and validity needs to be established by comparison to existing code. 
- Some cleanup is needed

## Appetite / Project Plan

1 FTE

This task does not require prior DaCe knowledge.