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

Flowmachine pareto #1044

Merged
merged 13 commits into from
Jul 10, 2019
Merged

Flowmachine pareto #1044

merged 13 commits into from
Jul 10, 2019

Conversation

BhavinPanch
Copy link
Contributor

@BhavinPanch BhavinPanch commented Jul 5, 2019

Closes #1012

I have:

  • Formatted any Python files with black
  • Brought the branch up to date with master
  • Added any relevant Github labels
  • Added tests for any new additions
  • Added or updated any relevant documentation
  • Added an Architectural Decision Record (ADR), if appropriate
  • Added an MPLv2 License Header if appropriate
  • Updated the Changelog

Expose Pareto interactions via FlowAPI's joined spatial aggregate endpoint.

@BhavinPanch BhavinPanch added enhancement New feature or request FlowClient Issues related to FlowClient FlowMachine Issues related to FlowMachine labels Jul 5, 2019
@BhavinPanch BhavinPanch requested a review from maxalbert July 5, 2019 11:08
query_kind = fields.String(validate=OneOf(["pareto_interactions"]))
start = fields.Date(required=True)
stop = fields.Date(required=True)
proportion = fields.Float(required=True)
Copy link
Contributor

@maxalbert maxalbert Jul 9, 2019

Choose a reason for hiding this comment

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

Can we please add a validate parameter here to ensure that proportion is a value (strictly) between 0.0 and 1.0?

Copy link
Contributor

@maxalbert maxalbert left a comment

Choose a reason for hiding this comment

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

Looks good. 👍

A couple of minor inline comments, then this is ready to merge (after resolving merge conflicts due to a previous PR having been merged already).

@codecov
Copy link

codecov bot commented Jul 10, 2019

Codecov Report

Merging #1044 into master will decrease coverage by 1.21%.
The diff coverage is 50%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1044      +/-   ##
==========================================
- Coverage   91.23%   90.02%   -1.22%     
==========================================
  Files         141       16     -125     
  Lines        6786     1393    -5393     
  Branches      662       57     -605     
==========================================
- Hits         6191     1254    -4937     
+ Misses        483      131     -352     
+ Partials      112        8     -104
Flag Coverage Δ
#flowapi_unit_tests 82.4% <ø> (ø) ⬆️
#flowauth_unit_tests 94.86% <ø> (ø) ⬆️
#flowclient_unit_tests 80.82% <50%> (-0.29%) ⬇️
#flowetl_unit_tests ?
#flowkit_jwt_generator_unit_tests 100% <ø> (ø) ⬆️
#flowmachine_unit_tests ?
Impacted Files Coverage Δ
flowclient/flowclient/client.py 80.82% <50%> (-0.29%) ⬇️
...achine/core/server/query_schemas/daily_location.py
...e/flowmachine/features/raster/raster_statistics.py
flowetl/etl/etl/etl_utils.py
flowmachine/flowmachine/core/custom_query.py
flowmachine/flowmachine/core/server/server.py
...hine/features/location/unique_subscriber_counts.py
...ne/core/server/query_schemas/radius_of_gyration.py
...owmachine/features/subscriber/subscriber_degree.py
flowmachine/flowmachine/core/grid.py
... and 115 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 2948654...900ae2a. Read the comment docs.

@codecov
Copy link

codecov bot commented Jul 10, 2019

Codecov Report

Merging #1044 into master will increase coverage by 0.02%.
The diff coverage is 100%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1044      +/-   ##
==========================================
+ Coverage   94.03%   94.06%   +0.02%     
==========================================
  Files         144      145       +1     
  Lines        7030     7055      +25     
  Branches      694      694              
==========================================
+ Hits         6611     6636      +25     
  Misses        309      309              
  Partials      110      110
Flag Coverage Δ
#flowapi_unit_tests 82.4% <ø> (ø) ⬆️
#flowauth_unit_tests 94.86% <ø> (ø) ⬆️
#flowclient_unit_tests 80.63% <50%> (-0.28%) ⬇️
#flowetl_unit_tests 100% <ø> (ø) ⬆️
#flowkit_jwt_generator_unit_tests 100% <ø> (ø) ⬆️
#flowmachine_unit_tests 91.04% <73.91%> (-0.08%) ⬇️
#integration_tests 64.18% <100%> (+0.73%) ⬆️
Impacted Files Coverage Δ
...e/server/query_schemas/joined_spatial_aggregate.py 100% <100%> (ø) ⬆️
...e/core/server/query_schemas/pareto_interactions.py 100% <100%> (ø)
flowclient/flowclient/client.py 94.59% <100%> (+0.04%) ⬆️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update d3f9d4d...94b5a7b. Read the comment docs.

@maxalbert
Copy link
Contributor

Thanks for the changes! 👍

Nearly ready to merge, the only missing bit is to add a validate parameter in the proportions field of ParetoInteractionsSchema (see inline comment in query_schemas/pareto_interactions.py ).

@maxalbert
Copy link
Contributor

Sorry, my bad. Github was pointing me to an old revision, but I saw you already changed this so this is good to go. Thanks!

@maxalbert maxalbert merged commit 10a4c85 into master Jul 10, 2019
@maxalbert maxalbert deleted the flowmachine-pareto branch July 10, 2019 14:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request FlowClient Issues related to FlowClient FlowMachine Issues related to FlowMachine
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enable Pareto via api
2 participants