Skip to content

Commit

Permalink
production push
Browse files Browse the repository at this point in the history
  • Loading branch information
wolfiex committed Nov 30, 2024
1 parent ef62c15 commit 385a1cd
Show file tree
Hide file tree
Showing 4,273 changed files with 447,720 additions and 0 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
Binary file added data_descriptors/.DS_Store
Binary file not shown.
Empty file added data_descriptors/.nojekyll
Empty file.
27 changes: 27 additions & 0 deletions data_descriptors/404.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Load JSON Key Display</title>
<link rel='stylesheet' href='https://bootswatch.com/5/sketchy/bootstrap.css'>
<style>
body { padding:10px; }
h2 { font-size:0.8rem; margin-left: 10px }
h3 { font-size:0.6rem; margin-left: 15px ; color:gray }
p { margin-left: 30px }
pre {border: none; padding:40px}
ul {padding-left: 40px}
</style>
</head>
<body>
<h1 id='title'>Data Descriptor</h1>
<div>
<code id="content"></code>
</div>

<script src='https://wcrp-cmip.github.io/CMIP-LD/static/404_restful.js'>

</script>
</body>
</html>
14 changes: 14 additions & 0 deletions data_descriptors/_context_
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
{
"@context": {
"@base": "https://wcrp-cmip.github.io/MIP-variables/",
"@vocab": "https://wcrp-cmip.github.io/MIP-variables/",
"id": "@id",
"type": "@type",
"cf": "https://wcrp-cmip.github.io/CF/",
"cmip6plus": "https://wcrp-cmip.github.io/CMIP6Plus_CVs/",
"cmip7": "https://wcrp-cmip.github.io/CMIP7_CVs/",
"mip-variables": "https://wcrp-cmip.github.io/MIP-variables/",
"wcrp-universe": "https://wcrp-cmip.github.io/WCRP-UNIVERSE/"
},
"@embed": "@always"
}
66 changes: 66 additions & 0 deletions data_descriptors/deldrdr.ipynb
Original file line number Diff line number Diff line change
@@ -0,0 +1,66 @@
{
"cells": [
{
"cell_type": "code",
"execution_count": 5,
"metadata": {},
"outputs": [],
"source": [
"import os, glob, json, sys, re\n",
"from collections import OrderedDict"
]
},
{
"cell_type": "code",
"execution_count": 6,
"metadata": {},
"outputs": [],
"source": [
"tables = glob.glob('tables/*.json')\n",
"\n",
"for i in tables:\n",
" with open(i) as f:\n",
" data = json.load(f)\n",
" data['type'] = 'mip_table'\n",
" data['product'] = {'id': f\"{data['product']}.json\"}\n",
" \n",
" # https://wcrp-cmip.github.io/WCRP-UNIVERSE/data_descriptors/product/\n",
" \n",
" data = OrderedDict(sorted(data.items()))\n",
" \n",
" json.dump(data, open(i, 'w'), indent=4)\n",
" \n",
"\n",
" "
]
},
{
"cell_type": "code",
"execution_count": null,
"metadata": {},
"outputs": [],
"source": []
}
],
"metadata": {
"kernelspec": {
"display_name": "base",
"language": "python",
"name": "python3"
},
"language_info": {
"codemirror_mode": {
"name": "ipython",
"version": 3
},
"file_extension": ".py",
"mimetype": "text/x-python",
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.10.10"
}
},
"nbformat": 4,
"nbformat_minor": 2
}
Loading

0 comments on commit 385a1cd

Please sign in to comment.