Commit 8d9aa3b7 authored by Jungho Shin's avatar Jungho Shin
Browse files

making interface to Repository

parent a13eefc4
......@@ -6,7 +6,7 @@ from nomadcore.parser_backend import JsonParseEventsWriterBackend
from nomadcore.parse_streamed_dicts import *
import logging
from nomadrepo.parsers import Output
from nomadrepo.core.api import API
base_path = os.path.abspath(os.path.dirname(__file__))
......@@ -17,10 +17,7 @@ def calculateTags(inputDict, backend, calcUri):
else:
backend.openContext(calcUri)
repoSect = backend.openSection("section_repository_info")
print ("< ##### inputDict ##### ", inputDict, "##### >")
print ("***", inputDict.keys(), "***")
print ("Output:", Output)
#help(backend.addValue)
# fill out i.e. backend.addValue unsing input Dict
# "repository_checksum",
# "repository_chemical_formula",
......@@ -34,6 +31,12 @@ def calculateTags(inputDict, backend, calcUri):
# "repository_system_type",
# "repository_xc_treatment"
# add more?
#print("\n*** inputDict %s *** \n", inputDict)
work = API()
calc, error = work._parse(inputDict, "normalizerRepo")
print("\n*** calc %s *** \n", calc)
if repoSectUri:
backend.closeContext(repoSectUri)
else:
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment