-
Notifications
You must be signed in to change notification settings - Fork 7
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
Add read_metadata()
function
#26
Add read_metadata()
function
#26
Conversation
It could be useful outside the submodule.
This is essentially a small wrapper to read_header, which just returns the metadata from the specified file. Closes ImperialCollegeLondon#25.
It looks like #24 needs to be merged first. |
Codecov Report
@@ Coverage Diff @@
## develop #26 +/- ##
===========================================
+ Coverage 92.24% 92.36% +0.11%
===========================================
Files 3 3
Lines 129 131 +2
===========================================
+ Hits 119 121 +2
Misses 10 10
📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I understand this is just a convenience function, but is it really that much advantage compared to just doing read_header(filename, marker, **kwargs)[0]
, which is all it is?
If you think it is, then you will need to add the corresponding test.
I think it is useful as a convenience function, though that's obviously a bit subjective! I've added a test now. |
Closes #25.
It would be handy to be able to read just the metadata from a data file without having to load everything else. I've added a new
read_metadata()
function to do this.