Comments (10)
A (2, 2)
B (3, 2)
Concat A B (5, 2)
from metadsl.
Take 2 (Concat A B) (2 2)
from metadsl.
Want to remove conditional statement if we know outer shape is 2 so idx[0] will always be less than 2
def idx_fn(idx):
if idx[0] < 2:
return A[idx[0], *idx[1:]]
return B[idx[0] - 2, *idx[1:]]
idx_fn(0, 0)
idx_fn(0, 1)
idx_fun(1, 0)
idx_fun(1, 1)
from metadsl.
Generated code:
for i in range(2):
for j in range(2)
a[i, j] = idx_fun(i, j)
from metadsl.
http://docs.idris-lang.org/en/latest/tutorial/typesfuns.html#the-finite-sets
from metadsl.
Maybe we need set arithmetic:
Sympy has range and interval types
from metadsl.
from metadsl.
Could be reimplemented in uarray without relying on sympy: https://en.wikipedia.org/wiki/Interval_arithmetic
from metadsl.
Notebook aaron created to try out interval types: http://nbviewer.jupyter.org/gist/saulshanabrook/57edd46cdc3b52ec4904dc9ab2d07307
from metadsl.
Could possibly be done with "analysis" of egg, if we want to go that way
from metadsl.
Related Issues (20)
- Refactor internals to use own type representation
- Fix doctests
- Fix Python 3.9-3.10 errors
- Host viewer as jupyter widget
- Fix serializing parameterized typs
- Add backend that compiles to NumPy to show E2E system that is a no-op
- Tony Notes
- Compare with `typy` HOT 2
- Blog post comparing to NumPy Mixin HOT 1
- Generic Constructors HOT 8
- updating metadsl docs - roadmap/vision
- Seperate replacements into steps
- Generate metadsl from linked data
- Create interface to REDUCE
- images HOT 6
- Refactor internals to use own type representation HOT 1
- EPython notes
- Remove uarray tags HOT 1
- TypeError: Cannot match concrete type <class '__main__.Number'> with hint <class 'int'> HOT 7
- Integrate with MLIR HOT 1
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 metadsl.