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

Schutz inequality measures #75

Merged
merged 23 commits into from
Sep 1, 2024
Merged

Schutz inequality measures #75

merged 23 commits into from
Sep 1, 2024

Conversation

sjsrey
Copy link
Member

@sjsrey sjsrey commented Aug 21, 2024

No description provided.

@sjsrey sjsrey added the enhancement New feature or request label Aug 21, 2024
Copy link

codecov bot commented Aug 21, 2024

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.7%. Comparing base (3bea348) to head (b7a0947).
Report is 29 commits behind head on main.

Additional details and impacted files

Impacted file tree graph

@@           Coverage Diff           @@
##            main     #75     +/-   ##
=======================================
+ Coverage   96.3%   96.7%   +0.4%     
=======================================
  Files          5       7      +2     
  Lines        433     491     +58     
=======================================
+ Hits         417     475     +58     
  Misses        16      16             
Files with missing lines Coverage Δ
inequality/__init__.py 100.0% <100.0%> (ø)
inequality/atkinson.py 100.0% <100.0%> (ø)
inequality/schutz.py 100.0% <100.0%> (ø)

... and 1 file with indirect coverage changes

inequality/atkinson.py Outdated Show resolved Hide resolved
inequality/atkinson.py Outdated Show resolved Hide resolved
@knaaptime
Copy link
Member

knaaptime commented Aug 22, 2024

(note to self: continue to always check for 'pending' status on reviews moving forward)

@knaaptime
Copy link
Member

(also, i think you started the schutz branch from your atkinson branch, so this commit includes both additions). Can probably close #74

inequality/schutz.py Show resolved Hide resolved
inequality/schutz.py Outdated Show resolved Hide resolved
inequality/schutz.py Outdated Show resolved Hide resolved
sjsrey and others added 2 commits August 22, 2024 11:38
Co-authored-by: James Gaboardi <[email protected]>
Co-authored-by: James Gaboardi <[email protected]>
@jGaboardi
Copy link
Member

Seems like we need to increase the timeout on the testing workflow. There Mac and Windows aren't finish within 30 minutes, but they almost are...

@jGaboardi
Copy link
Member

Probably bumping to 35 minutes should do the trick.

@knaaptime
Copy link
Member

kinda taking awile for not a ton of functionality. Have we turned on parallel tests here yet?

@martinfleis
Copy link
Member

The timeout comes only on Mac and Win and only in this PR. Given ubuntu runs in under a minute, I smell some issue related to non-linux runtime of something in this PR. If that is the case, bumping the timeout is probably not the optimal solution but we should figure out what is causing so massive performance difference.

@sjsrey
Copy link
Member Author

sjsrey commented Aug 22, 2024

My suspicion has to do with some tests I added for the plots. Trying to get the blessing of the codecov gods, I added some tests to cover, well everything. When I run them locally, separate windows actually get generated locally now (just noticed this this morning).
I'm at a loss as to why linux can handle this, but not macos or windows on the ci. But I can revisit the tests to make them less troublesome.

assert pytest.approx(schutz_obj.coefficient, 0.1) == expected_coefficient


def test_schutz_plot_runs_without_errors(example_dataframe):
Copy link
Member Author

Choose a reason for hiding this comment

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

Check if this is causing the timeout on mac and windows ci.

@jGaboardi
Copy link
Member

kinda taking awile for not a ton of functionality. Have we turned on parallel tests here yet?

pytest-xdist is enabled

@sjsrey sjsrey merged commit 03ca561 into pysal:main Sep 1, 2024
10 checks passed
@@ -0,0 +1,197 @@
import matplotlib.pyplot as plt
Copy link
Member

Choose a reason for hiding this comment

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

Inequality does not depend on matplotlib as of now, so this either needs to be imported in a function or we need to add matplotlib to dependencies. This is now failing momepy CI which is tested against dev inequality.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants