| 1262 | } |
| 1263 | |
| 1264 | void json_add_node_bias(struct json_stream *js, |
| 1265 | const char *fieldname, |
| 1266 | const struct node_bias *b, |
| 1267 | const struct layer *layer) |
| 1268 | { |
| 1269 | json_object_start(js, fieldname); |
| 1270 | if (layer) |
| 1271 | json_add_string(js, "layer", layer->name); |
| 1272 | json_add_node_id(js, "node", &b->node); |
| 1273 | if (b->description) |
| 1274 | json_add_string(js, "description", b->description); |
| 1275 | json_add_s64(js, "in_bias", b->in_bias); |
| 1276 | json_add_s64(js, "out_bias", b->out_bias); |
| 1277 | json_add_u64(js, "timestamp", b->timestamp); |
| 1278 | json_object_end(js); |
| 1279 | } |
| 1280 | |
| 1281 | static void json_add_layer(struct json_stream *js, |
| 1282 | const char *fieldname, |
no test coverage detected