Adding metadata to the new dataset
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 459
- Forks
- 359
- Avg merge
- 3d 6h
- Merged PRs (30d)
- 73
Description
If I use the dataset as created by
` dataset = qc. new_data_set('results', specs=[some_paramspec]) `
then I can add metadata to it like:
`dataset.add_metadata('measurement_notes', 'really warm today')`
but if I use the `Measurement` object to create a dataset like:
```python
analysis_meas = Measurement()
analysis_meas.register_parameter(some_parameter)
with analysis_meas.run() as datasaver:
datasaver.add_result((some_parameter.name, 5))
```
Then I don't see how I am meant to add metadata as neither `Measurement` nor `Datasaver` have an easy way to access the dataset or to add metadata.
In a related note it would be great to have an example of adding metadata in the examples and similarly of retrieving it (minimally how to retrieve the snapshot should be there unless I'm missing something(?)).
@jenshnielsen @Dominik-Vogel @WilliamHPNielsen @cgranade
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the Measurement and Datasaver APIs and the existing new_data_set metadata usage. Trace how the dataset is created inside Measurement.run(), then determine how metadata and snapshot retrieval should be exposed and documented. Done means metadata can be added and retrieved through the Measurement/Datasaver workflow, with examples covering both operations.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100