hi !
ocramz / ad-delcont Goto Github PK
View Code? Open in Web Editor NEWReverse-mode automatic differentiation with delimited continuations
License: BSD 3-Clause "New" or "Revised" License
Reverse-mode automatic differentiation with delimited continuations
License: BSD 3-Clause "New" or "Revised" License
hi !
Currently, the core abstraction of this library is ContT r (ST s) a
. This loosely follows from the design of Wang, ICFP'19 since we need both the continuation monad and mutable references.
However, since the results are numerically incorrect, (see rad (\x -> x + x) 2
for example), a redesign is in order.
g . f
where g
and f
are fixed), to elucidate the interplay of continuations and mutable references.Simple example with fibonacci numbers:
n :: Int
n = 50
fibN :: Num a => a -> a
fibN x0 = fibs !! n
where
fibs = 0 : x0 : zipWith (+) fibs (tail fibs)
fibInt :: Integer
fibInt = fibN 1
fibAD :: (Integer, Integer)
fibAD = rad1g 0 1 fibN 1
fibInt
evaluates instantly. fibAD
takes a long time and throws stack overflow exception.
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.