Skip to content
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

[ENH] MI and CMI simulation module and relevant estimators from the forest #83

Merged
merged 19 commits into from
Jun 20, 2023

Conversation

adam2392
Copy link
Collaborator

Fixes #49
Fixes #48
Supersedes: #58

Changes proposed in this pull request:

  • simulation for MI and CMI data

Before submitting

  • I've read and followed all steps in the Making a pull request
    section of the CONTRIBUTING docs.
  • I've updated or added any relevant docstrings following the syntax described in the
    Writing docstrings section of the CONTRIBUTING docs.
  • If this PR fixes a bug, I've added a test that will fail without my fix.
  • If this PR adds a new feature, I've added tests that sufficiently cover my new functionality.

After submitting

  • All GitHub Actions jobs for my pull request have passed.

Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
@codecov
Copy link

codecov bot commented Jun 12, 2023

Codecov Report

Patch coverage: 69.21% and project coverage change: -7.07 ⚠️

Comparison is base (2768558) 93.39% compared to head (7463904) 86.33%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main      #83      +/-   ##
==========================================
- Coverage   93.39%   86.33%   -7.07%     
==========================================
  Files          16       24       +8     
  Lines        1469     1924     +455     
==========================================
+ Hits         1372     1661     +289     
- Misses         97      263     +166     
Impacted Files Coverage Δ
sktree/experimental/mutual_info.py 20.51% <20.51%> (ø)
sktree/experimental/tests/test_mutual_info.py 62.06% <62.06%> (ø)
sktree/tree/_marginalize.py 76.74% <76.74%> (ø)
sktree/neighbors.py 86.20% <86.20%> (ø)
sktree/experimental/simulate.py 88.13% <88.13%> (ø)
sktree/__init__.py 79.16% <100.00%> (+0.90%) ⬆️
sktree/ensemble/_supervised_forest.py 100.00% <100.00%> (ø)
sktree/ensemble/_unsupervised_forest.py 70.63% <100.00%> (+0.23%) ⬆️
sktree/experimental/__init__.py 100.00% <100.00%> (ø)
sktree/experimental/tests/test_simulate.py 100.00% <100.00%> (ø)
... and 6 more

☔ View full report in Codecov by Sentry.
📢 Do you have feedback about the report comment? Let us know in this issue.

Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Copy link
Collaborator Author

@adam2392 adam2392 Jun 15, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@YuxinB @PSSF23 @jovo in case you're interested, this is the method for marginalizing a fitted tree using the ideas that have been discussed.

This file and _marginal.pyx are the core files.

Specifically, I implement some ideas for traversing the tree, while "marginalizing out features".

@adam2392
Copy link
Collaborator Author

Next, I need to add now a simulation using a fitted forest and computing a bunch of quantities for MI/CMI

Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
Signed-off-by: Adam Li <adam2392@gmail.com>
@adam2392 adam2392 merged commit 7eb96e6 into main Jun 20, 2023
19 of 22 checks passed
@adam2392 adam2392 deleted the cmi branch June 20, 2023 17:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
1 participant