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

Temporary draft PR to identify notebook test failure cause #600

Draft
wants to merge 36 commits into
base: main
Choose a base branch
from
Draft
Changes from all commits
Commits
Show all changes
36 commits
Select commit Hold shift + click to select a range
fa4e28e
removes nested for loops; reduces n to 500
Feb 17, 2022
a4eb09f
linting fixes
Feb 17, 2022
dc47b6a
reorganize imports
Feb 17, 2022
8e4682f
removes unused imports
Feb 23, 2022
2cb7f40
runs tree tests serially
Feb 23, 2022
0cccf37
fixes typo
Feb 23, 2022
684e1c7
linting fix
Feb 23, 2022
0b951fd
reorganize imports
Feb 23, 2022
d1068c0
run test serially
Feb 23, 2022
33c580f
adds tags for cate_api tests
Feb 23, 2022
caba5ce
sets up new test marks in azure pipelin
Feb 23, 2022
a588897
fixes typo in pipeline yml
Feb 23, 2022
0da6860
debug pipeline
Feb 23, 2022
fd5b3e2
reorganize imports
Feb 24, 2022
ae7086b
adds back dependency
Feb 24, 2022
57afa35
remove unused imports
Feb 24, 2022
64c0c7f
reduce size of matrix by half
Feb 24, 2022
3d7340d
reverts n
Feb 24, 2022
194743e
moves test_statsmodels to serial testing
Feb 24, 2022
ac28cf0
combines other tests to single job
Feb 25, 2022
2ac1aa6
removes nested loops from test_random_state
Feb 25, 2022
78c0391
fixes indenting
Feb 25, 2022
b6b6f49
tries running causal tests in parallel
Feb 25, 2022
b36a2cb
remove unnecessary deps
Feb 25, 2022
1ea012b
linting fix
Feb 25, 2022
7664f75
reverts to run causal tests serially
Feb 25, 2022
b94f454
correctly tags stats models
Feb 25, 2022
e943f99
re-enables pickling test
Mar 8, 2022
fea98c5
uncomments options
Mar 8, 2022
691ea6e
reorganizes unit test workflow
Mar 8, 2022
01c8001
Consolidate test marks
kbattocchi Mar 30, 2022
6ad3315
Update numpy test dependency
kbattocchi Apr 1, 2022
564af9e
Revert numpy version
kbattocchi Apr 4, 2022
96d7292
Remove workaround for downlevel shap
kbattocchi Apr 5, 2022
4e8d0df
Add GC collections
kbattocchi Apr 5, 2022
8e68553
Merge branch 'main' into kebatt/debugNotebooks
kbattocchi Apr 6, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions econml/tests/test_causal_analysis.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
from numpy.core.fromnumeric import squeeze
import pandas as pd
import pytest
import gc

from econml.solutions.causal_analysis import CausalAnalysis
from econml.solutions.causal_analysis._causal_analysis import _CausalInsightsConstants
Expand Down Expand Up @@ -692,6 +693,9 @@ def test_random_state(self):
np.testing.assert_equal(glo.point.values, glo2.point.values)
np.testing.assert_equal(glo.stderr.values, glo2.stderr.values)

del ca, glo, ca2, glo2
gc.collect()

def test_can_set_categories(self):
y = pd.Series(np.random.choice([0, 1], size=(500,)))
X = pd.DataFrame({'a': np.random.normal(size=500),
Expand Down Expand Up @@ -785,6 +789,9 @@ def test_invalid_inds(self):
self.assertEqual(ca.untrained_feature_indices_, [(4, 'cat_limit'),
(5, 'cat_limit')])

del ca
gc.collect()

# Add tests that guarantee that the reliance on DML feature order is not broken, such as
# Creare a transformer that zeros out all variables after the first n_x variables, so it zeros out W
# Pass an example where W is irrelevant and X is confounder
Expand Down