Commit Graph

7 Commits

Author SHA1 Message Date
Daniel YU 7316062c10 upgrade to ghc 8.6.4 (#237) 2019-04-11 19:27:15 -07:00
Christian Berentsen 61e58fd33f Use proto-lens* == 0.3.* (#212)
* Include more *_Fields modules
2018-09-04 10:44:52 -07:00
Erlend Hamberg 88dafe8f3a Update to LTS-11 (#187)
Fix Conduit 1.3 deprecation warnings
- The `Conduit`, `Producer` and `Consumer` aliases are deprecated and
  `ConduitT` is used directly instead
- `=$=` is deprecated and replaced by `.|`
2018-05-18 19:20:11 -04:00
Christian Berentsen f2cafa7071 Added imageSummary wrapper (#159) 2018-01-23 13:02:58 -05:00
Christian Berentsen 042910b000 Added logGraph for graph visualization in TensorBoard (#104) 2017-06-19 20:53:55 -07:00
Judah Jacobson d62c614695 Distinguish between "rendered" and "unrendered" Tensors. (#88)
Distinguish between "rendered" and "unrendered" Tensors.

There are now three types of `Tensor`:

- `Tensor Value a`: rendered value
- `Tensor Ref a`: rendered reference
- `Tensor Build a` : unrendered value

The extra bookkeeping makes it easier to track (and enforce) which tensors are
rendered or not.  For examples where this has been confusing in the past, see

With this change, pure ops look similar to before, returning `Tensor Build`
instead of `Tensor Value`.  "Stateful" (monadic) ops are unchanged.  For
example:

    add :: OneOf [..] t => Tensor v'1 t -> Tensor v'2 t -> Tensor Build t
    assign :: (MonadBuild m, TensorType t)
           => Tensor Ref t -> Tensor v'2 t -> m (Tensor Ref t)

The `gradients` function now requires that the variables over which it's
differentiating are pre-rendered:

    gradients :: (..., Rendered v2) => Tensor v1 a -> [Tensor v2 a]
              -> m [Tensor Value a]

(`Rendered v2` means that `v2` is either a `Ref` or a `Value`.)

Additionally, the implementation of `gradients` now takes care to render every
intermediate value when performing the reverse accumulation.  I suspect this
fixes an exponential blowup for complicated expressions.
2017-04-06 15:10:33 -07:00
fkm3 b3c0997a8c Add support for logging to tensorboard (#74)
Add support for logging to tensorboard

Based on @gnezdo's internal version with some differences:

* Uses a pure haskell implementation of EventWriter instead of FFI.
* Special `buildAnd*` functions were dropped in favor of using
  `mergeAllSummaries :: Build SummaryTensor` with the normal
  `build` function.
2017-02-20 19:16:42 -08:00