File Structure
Closed this issue · 3 comments
There are a number of file / code structure things that I think we need to address.
I'm keen to follow our KernelFunctions test style in this package, because it makes it easy to predict roughly where stuff is tested, and to avoid near-circular dependencies in testing.
Specific things I think we need to change:
- I can't see a particuarly good reason to have the elbo-related code separate from the
sparse_variational
code, and it makes testing a bit of a headache, because you wind up having to instantiateSparseVariationalApproximations
more times than would be ideal. - I would like the consistency tests be located with the code that they're testing ie. inside
test/sparse_variational.jl
, so that it's easy to see whats' going on.
Therefore I propose to
- add KernelFunctions test style guide to
test/runtests.jl
- move code from
src/elbo.jl
intosrc/sparse_variational.jl
, and removesrc/elbo.jl
- move tests from
test/elbo.jl
intotest/sparse_variational.jl
and removetest/elbo.jl
- move tests from
test/equivalences.jl
insidetest/sparse_variational.jl
.
@rossviljoen does this seem reasonable to you? Were there particular ways to structure things in this way that I'm missing?
That seems eminently reasonable! I think the only reason I put equivalences in a different file was because I thought it might be too heavy to run all the time - but that's a nonissue so it makes sense to put them all in the same place
I'll do this in a PR along with #66
Edit: Never mind, better to do them separately
Closed by #78