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

GAIA: Add optional 'columns' parameter to select specific columns. #1548

Merged
merged 3 commits into from
Dec 10, 2019

Conversation

tcaram
Copy link
Contributor

@tcaram tcaram commented Sep 14, 2019

Hey! Some of the functions from the Gaia submodule (cone_search and query_object) are lacking a 'columns' parameter to query only for specific columns. Querying only for the desired columns would reduce the bandwidth and memory used every time you query for an object or do a cone search. My version of the code is compatible with old ones, as it adds an optional parameter that behaves just like it used to (in previous versions) if it's not set.

Added optional 'columns' parameter to query_object and cone_search so you can select only the desired columns and save bandwidth and meory.
Added optional 'columns' parameter to query_object and cone_search so you can select only the desired columns and save bandwidth and meory.
@pep8speaks
Copy link

pep8speaks commented Sep 14, 2019

Hello @tcaram! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

There are currently no PEP 8 issues detected in this Pull Request. Cheers! 🍻

Comment last updated at 2019-09-14 15:56:02 UTC

@astropy-bot astropy-bot bot added the gaia label Sep 14, 2019
@codecov
Copy link

codecov bot commented Sep 14, 2019

Codecov Report

Merging #1548 into master will increase coverage by <.01%.
The diff coverage is 75%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master    #1548      +/-   ##
==========================================
+ Coverage   62.42%   62.42%   +<.01%     
==========================================
  Files         176      176              
  Lines       14635    14641       +6     
==========================================
+ Hits         9136     9140       +4     
- Misses       5499     5501       +2
Impacted Files Coverage Δ
astroquery/gaia/core.py 82.94% <75%> (-0.8%) ⬇️

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 073ea20...f6f397c. Read the comment docs.

Copy link
Contributor

@keflavich keflavich left a comment

Choose a reason for hiding this comment

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

I like this change. @jcsegovia, could you review? I don't see any reason not to merge this right now.

@jcsegovia
Copy link
Contributor

I agree @keflavich, I think it is quite useful and I do not see any problem with these changes.
Thanks @tcaram.

@keflavich keflavich merged commit 41a0e51 into astropy:master Dec 10, 2019
@bsipocz bsipocz added this to the 0.4 milestone Dec 10, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants