Skip to content

Commit

Permalink
add spec folder to validation testing cell in notebook
Browse files Browse the repository at this point in the history
  • Loading branch information
gtsueng committed Dec 21, 2023
1 parent 1aaf021 commit 9e0889e
Showing 1 changed file with 15 additions and 16 deletions.
31 changes: 15 additions & 16 deletions specification aggregator.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -6517,27 +6517,26 @@
},
{
"cell_type": "code",
"execution_count": 1,
"execution_count": 11,
"metadata": {},
"outputs": [
{
"name": "stderr",
"output_type": "stream",
"text": [
"C:\\Users\\gtsueng\\Anaconda3\\envs\\outbreak\\lib\\site-packages\\biothings_schema\\schema.py:281: UserWarning: Found multiple namespace prefixes defined in the schema: f['dwc', 'dct', 'bioschemas']\n",
" warnings.warn(f\"Found multiple namespace prefixes defined in the schema: f{namespace_set}\")\n"
]
}
],
"outputs": [],
"source": [
"from biothings_schema import Schema\n",
"import os\n",
"import json\n",
"\n",
"script_path = os.getcwd()\n",
"parent_path = os.path.dirname(script_path)\n",
"repo_path = os.path.join(parent_path,'specifications')\n",
"spec_name = 'LabProtocol'\n",
"file_name = 'LabProtocol_v0.8-DRAFT.json'\n",
"file_path = os.path.join(repo_path,spec_name,'jsonld',file_name)\n",
"with open(file_path,'r') as infile:\n",
" url = json.load(infile)\n",
"\n",
"script_path = ''\n",
"#url = \"https://raw.githubusercontent.com/gtsueng/DDE_bioschemas/main/draft_validations/ProteinStructure_v0.5-DRAFT-2018_08_15.json\"\n",
"url = \"https://raw.githubusercontent.com/BioSchemas/bioschemas-dde/main/bioschemas.json\"\n",
"#bioschemasfile = os.path.join(script_path,'bioschemas.json')\n",
"#with open(bioschemasfile,'r') as infile:\n",
"# url = json.load(infile)\n",
"#url = \"https://raw.githubusercontent.com/BioSchemas/bioschemas-dde/main/bioschemas.json\"\n",
"\n",
"\n",
"sc = Schema(url, base_schema=[\"schema.org\",\"bioschemastypes\",\"bioschemas\",\n",
" \"bioschemasdrafts\",\"bioschemastypesdrafts\",\n",
Expand Down

0 comments on commit 9e0889e

Please sign in to comment.