Comments (4)
That's not a bad intermediate test case, but will require a fair bit of basics to be right (but I don't see any fundamental issues).
My next step is to model the numpy ufunc abstraction in the numpy MLIR dialect. There are a few ways to do it, but I'm thinking of having a ufunc_call
op which references a module level ufunc
(which could be of a few different types) that holds the metadata about the operation.
Since the ufunc is such a core abstraction within numpy, and since it covers so many of the fundamental operations, it makes sense to me to spend some time to get it modeled isomorphic to how numpy reasons about it (at least modeling a proper subset of cases).
Beyond that, for your example, we would need:
- Indexing/slicing ops
- Some 'constructor ops' (zeros, etc)
where
dot
I'm trying to model it as isomorphic to numpy as is reasonable, since that is part of the MLIR philosophy and makes the tracer/ast-importer really-really thin, leaving the hard work to the compiler infra, which (in theory) is where we have the best tooling.
I'm going to try to get a first draft of the numpy dialect ~this week. I've been thinking on the design of it, but the limited time I've had to actually work on it has been swallowed up by setup/build issues (which I think I'm past now).
from mlir-npcomp.
Probably we could reply to this stackoverflow question one of these days.
from mlir-npcomp.
Not touching the question of what TensorFlow should be doing, getting this modeled right is a big driver of my work here. Lacking this functionality has been a drag on research adjacent to me for quite some time.
from mlir-npcomp.
Of course, but I hope it will have repercussions elsewhere.
from mlir-npcomp.
Related Issues (3)
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mlir-npcomp.