spcl / stencilflow Goto Github PK
View Code? Open in Web Editor NEWLicense: BSD 3-Clause "New" or "Revised" License
License: BSD 3-Clause "New" or "Revised" License
Hi there,
I am interested in optimising a stencil code written in Python using StencilFlow. From what I see in the repository and from what I read on your paper it is possible to do so by generating the SDFG from DACE and then transforming this into a JSON StencilFlow file with the tool bin/sdfg_to_stencilflow.py
. Unfortunately, I haven't been able to do so, as I'm getting the error ValueError: Program has no outputs
. Here a small code to reproduce:
import dace
import numpy as np
DIM = 10
@dace.program
def jacobi(a: dace.float64[DIM,DIM], b: dace.float64[DIM,DIM]):
for i in range(1,DIM-1):
for j in range(1,DIM-1):
b[i] = b[i] + 2*a[-1,0] - 2*a[1,0] + 2*a[0,-1] - 2*a[0,1]
if __name__ == "__main__":
a = np.array([[0 for j in range(DIM)] for i in range(DIM)], dtype=np.double)
b = np.array([[0 for j in range(DIM)] for i in range(DIM)], dtype=np.double)
jacobi(a,b)
I just fed the .sdfg
file in .dacecache/jacobi
to bin/sdfg_to_stencilflow.py
. Is there any fundamental annotation that's missing? I wouldn't want to modify the source code, is it possible to run StencilFlow on this code as-is other than some basic annotations?
Note: I am using the DACE version that is frozen as submodule in this repository.
Thanks,
Gabriel
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.