bokeh / bokeh-scala

Scala bindings for Bokeh plotting library
MIT License
135 stars 16 forks source link

Make breeze an optional depencency #4

Closed mattpap closed 8 years ago

mattpap commented 9 years ago

Currently bokeh depends on breeze, mainly to allow breeze.linalg.DenseVector[_] as a column type (and serialization). It would be better to make breeze optional to reduce dependency size and make a step towards scala.js compatibility. Most support for DenseVector is done through type classes, so it shouldn't be a problem to move them to a separate sub-project (e.g. lib or something like that) and then import as needed. The only issue is with serialization of Any (still required for ColumnDataSource). I tried to use a structural type instead of DenseVector[_] in anyToJson(), but this can fail with "method not found" upon reflection (the match is unchecked, resulting in a cast, possibly unsuccessful). If ColumnDataSource was improved to not use Any, then this issue would resolve by itself.

mattpap commented 8 years ago

breeze integration is now part of bokeh-thridparty.