HEPData / hepdata_lib

Library for getting your data into HEPData
https://hepdata-lib.readthedocs.io
MIT License
15 stars 39 forks source link

Add docs for `add_additional_resource` and support `type` argument #197

Closed GraemeWatt closed 10 months ago

GraemeWatt commented 2 years ago

An example of using the add_additional_resource function of the Submission or Table objects is not given in either the documentation or any of the example notebooks. This issue came up in a HEPData Forum post. It would be good to document the usage of add_additional_resource and apply it in one or more of the example notebooks.

Also, we just added a new feature to highlight HEPData records with attached HistFactory JSON files (search for analysis:HistFactory). Currently the "HistFactory" type is triggered by looking for certain words ("histfactory", "pyhf", "likelihoods", "workspaces") in the "description" for certain file types. But we now also allow a type: HistFactory field in the submission.yaml file to avoid relying on the description (see submission docs). So it would be good if add_additional_resource could also accept an optional argument type, then set resource["type"] = type.

clelange commented 2 years ago

+1 that would be good to have. Do you think you can pick this up @GraemeWatt ?