1
0
mirror of https://github.com/TREX-CoE/trexio.git synced 2025-04-26 02:14:54 +02:00

add package_version attribute to metadata group

This commit is contained in:
q-posev 2021-07-23 15:50:31 +02:00
parent 856412f06a
commit ba45479a8a

View File

@ -33,27 +33,29 @@ arrays are 0-based. Hence, we introduce the ~index~ type which is an
authors of the file, and a textual description. authors of the file, and a textual description.
#+NAME: metadata #+NAME: metadata
| Variable | Type | Dimensions (for arrays) | Description | | Variable | Type | Dimensions (for arrays) | Description |
|---------------+-------+-------------------------+------------------------------------------| |-------------------+-------+-------------------------+------------------------------------------|
| ~code_num~ | ~int~ | | Number of codes used to produce the file | | ~code_num~ | ~int~ | | Number of codes used to produce the file |
| ~code~ | ~str~ | ~(metadata.code_num)~ | Names of the codes used | | ~code~ | ~str~ | ~(metadata.code_num)~ | Names of the codes used |
| ~author_num~ | ~int~ | | Number of authors of the file | | ~author_num~ | ~int~ | | Number of authors of the file |
| ~author~ | ~str~ | ~(metadata.author_num)~ | Names of the authors of the file | | ~author~ | ~str~ | ~(metadata.author_num)~ | Names of the authors of the file |
| ~description~ | ~str~ | | Text describing the content of file | | ~package_version~ | ~str~ | | TREXIO version used to produce the file |
| ~description~ | ~str~ | | Text describing the content of file |
#+CALL: json(data=metadata, title="metadata") #+CALL: json(data=metadata, title="metadata")
#+RESULTS: #+RESULTS:
:results: :RESULTS:
#+begin_src python :tangle trex.json #+begin_src python :tangle trex.json
"metadata": { "metadata": {
"code_num" : [ "int", [] ] "code_num" : [ "int", [] ]
, "code" : [ "str", [ "metadata.code_num" ] ] , "code" : [ "str", [ "metadata.code_num" ] ]
, "author_num" : [ "int", [] ] , "author_num" : [ "int", [] ]
, "author" : [ "str", [ "metadata.author_num" ] ] , "author" : [ "str", [ "metadata.author_num" ] ]
, "description" : [ "str", [] ] , "package_version" : [ "str", [] ]
, "description" : [ "str", [] ]
} , } ,
#+end_src #+end_src
:end: :END:
* Electron (electron group) * Electron (electron group)