gia-ast
Version:
A CLI Wrapping AST Web API calls to servers
27 lines (23 loc) • 867 B
JavaScript
const fs = require('fs');
const { toASTMetaServer, aSTMetaServerToJson } = require('./AstMetaServer.js');
function createAndSaveMetadata() {
const data = {
"modelname": "model_gia-ds-ginko-2403g-864x_new",
"fname": "ginko-2403g",
"containername": "ast_ginko-2403g-864x_15m_s1_",
"containertag": "guillaumeai/server:ast-210502-compo-three-v2-dev",
"checkpointno": "15",
"svrtype": "s1",
"mtype": "ast",
"type": "singleone",
"autoabc": "",
"callurl": "http://localhost:9100/stylize",
"PASS1IMAGESIZE": "2048",
"getmetaurl": "http://localhost/9100.json",
"created": "Thu 21 Mar 2024 08:30:10 AM EDT"
};
const astMetaServerObject = toASTMetaServer(JSON.stringify(data));
const json = aSTMetaServerToJson(astMetaServerObject);
fs.writeFileSync('sample-out-mmetadata.json', json);
}
createAndSaveMetadata();