Repository navigation
Paginate Data Overview for wide datasets - #289
Open
Berserker-GM wants to merge 2 commits into
Open
Berserker-GM wants to merge 2 commits into
Berserker-GM wants to merge 2 commits into
Conversation
Compute and return only the requested page of features for local uploads and Globus, and keep dataset-wide counts complete.
Reset globusSummaryDropdownsReady in initWorkspace so dataset switches re-populate dropdowns, wrap the pager in a labeled nav, and add unit and integration coverage for the pagination helpers. Co-authored-by: Galaba Mohit <mohitgalba@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related Issues / Pull Requests
Closes #139
Description
Data Overview currently computes and renders summary statistics and a distribution chart for every feature, which is slow and heavy on wide datasets. This PR paginates both the summary table and Feature Distributions, and computes only the requested page on the server (it does not compute everything and hide the rest).
Behavior
/summary-statisticsaccepts optionalpageandpage_size(default 1 and 25, max 100). Statistics and histograms are computed only for that page's features.page/page_sizevalues are rejected.page/page_size, caches results per page, and uses the same shared helper (summary_pagination.py).Before / after (local measurements with the Flask test client; approximate, not a benchmark)
Notes for reviewers
summary_pagination_v1capability. An older worker gets a 409 "upgrade" response instead of falling back to computing everything. If you would prefer a (slow) fallback, I'm happy to change it.features_countis 1 whilepagination.total_featuresis 0. The pager is hidden there, so nothing visible is wrong, and I left the existing meaning offeatures_countunchanged./summary-statisticsare not documented in the Sphinx docs. Let me know if you want that added in this PR.How to test
PYTHONPATH=. pytest tests/integration/test_summary_statistics.py tests/integration/test_globus.py tests/unit/test_summary_pagination.py -vflask --app 'web:create_app()' run), upload a CSV with 40 or more columns, and page through. Totals stay fixed while the features change.Screenshots



What changes are proposed in this pull request?
Checklist: