-
Notifications
You must be signed in to change notification settings - Fork 14
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Triangulation-based estimators #55
base: main
Are you sure you want to change the base?
Conversation
Also, move to generator-style estimaton
DynamicalSystems not needed
Codecov Report
@@ Coverage Diff @@
## master #55 +/- ##
===========================================
- Coverage 74.90% 64.84% -10.06%
===========================================
Files 19 35 +16
Lines 522 933 +411
===========================================
+ Hits 391 605 +214
- Misses 131 328 +197
Continue to review full report at Codecov.
|
(i'm busy with some other projects at the moment and will look this at the end of the coming week) |
@kahaaga Sorry but we have to discuss this much more before merging. This adds a dependency on PyCall and Python, and I don't think Entropies.jl is should have such a dependency. It also contaminates DynamicalSystems.jl as well with it. What's the gain of having a python dependency, and what's the need? Julia has advanced quite a bit, are you sure there isn't some Julia implementation of what you need? (https://github.com/JuliaPolyhedra/QHull.jl is Python) |
The dependency on QHull is because of the need for N-dimensional Delaunay triangulations, which are necessary for the triangulation estimators to work. There is no native N-dimensional Julia implementation of that at the moment.
I agree. As a (poor) solution, in the current PR, I've hidden these estimators behind a @requires block, so that PyCall is not loaded until you actually need it (when loading However, this based on old code. I see that there is a relatively new I'll see if I can configure Simplices.jl downstream to use MiniQHull.jl instead, so that a dependency on Python here is not necessary. I'll tag you once I have news on that. |
@Datseris I had a talk with my collaborators, and we decided that this feature can wait a bit. It turned out to be a lot more work than expected to rewrite stuff to use the QHull library natively. Our plan is therefore to release CausalityTools 1.0 right away, if that's alright with you. |
Hi,
Do you need this PR merged to achieve that? |
@kahaaga you haven't requested feedback on TransferEntropy.jl or CausalityTools.jl docs first. Don't you think it would be useful for another pair of eyes to have a look before making the committment to 1.0? |
Looking over the PR, it changes 37 files. It even adds plotting recipes. What's going on here...? |
No, not needed.
We're doing a last round of checks on the docs in our group the next few days. I will tag you in the v1.0 PR in the CausalityTools repo when ready.
This doesn't need to go here. I'll remove the recipes.
I'll re-tag you once the QHull dependencies are done in Simplices.jl. Much of the stuff here will then be moved to that package, so less changes. |
Okay it all sounds good to me then! Perhaps it will even cleaner to open a brand new PR later down the line when things are ready! |
Yes, I think that is a good idea. I'll leave this open for now, just so that I can use CI testing while developing, and open a new PR when everything is cleaned up. |
TransferOperator
probabilities estimator now not only acceptsRectangularBinning
as an argument, but alsoSimplexPoint
andSimplexExact
, which uses a triangulated binning of the points.SimplexPoint
andSimplexExact
usesSimplices.jl
, which depends onPyCall
, so I used a@requires
block for this code to avoid long loading times for the package. That means the user has to runusing Simplices
after runningusing Entropies
. This is documented in the estimator docstrings.transfermatrix
totransitioninfo
. Entries of the triangulation-based transfer matrices correspond to simplices, not rectangular boxes. Therefore, to map probabilities of the transfer matrix to partition elements, we need info both about the vertices of the triangulation and which of these vertices form the different simplices. I have therefore created aTransitionInfo
return struct that accomodates this information, both for rectangular and triangulation-based binnings.The new estimators and behaviour is documented here.