From b4240eeaf7fea570f13d62aec47ce0604db4f1bb Mon Sep 17 00:00:00 2001 From: tpollina Date: Mon, 27 Jan 2020 16:30:31 -0800 Subject: [PATCH] Create store_retrieve.json --- flows/store_retrieve.json | 1170 +++++++++++++++++++++++++++++++++++++ 1 file changed, 1170 insertions(+) create mode 100644 flows/store_retrieve.json diff --git a/flows/store_retrieve.json b/flows/store_retrieve.json new file mode 100644 index 0000000..02147cb --- /dev/null +++ b/flows/store_retrieve.json @@ -0,0 +1,1170 @@ +[ + { + "id": "103f6179.d5012f", + "type": "tab", + "label": "Sample", + "disabled": false, + "info": "" + }, + { + "id": "f6f450aa.8ed73", + "type": "ui_text_input", + "z": "103f6179.d5012f", + "name": "sample_ship", + "label": "Name of the ship", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 5, + "width": 0, + "height": 0, + "passthru": true, + "mode": "text", + "delay": 300, + "topic": "sample_ship", + "x": 1170, + "y": 100, + "wires": [ + [ + "e17096e4.74caf8" + ] + ] + }, + { + "id": "8f3a0dab.4d614", + "type": "ui_dropdown", + "z": "103f6179.d5012f", + "name": "sample_sampling_gear", + "label": "Sampling gear", + "tooltip": "", + "place": "Select", + "group": "aac2eaf7.0cdab8", + "order": 7, + "width": 0, + "height": 0, + "passthru": true, + "options": [ + { + "label": "Plankton net", + "value": "net", + "type": "str" + }, + { + "label": "Niskin bottle 12L", + "value": "niskin_12L", + "type": "str" + }, + { + "label": "Niskin bottle 24L", + "value": "niskin_24L", + "type": "str" + }, + { + "label": "Pass Hull", + "value": "pass_hull", + "type": "str" + } + ], + "payload": "", + "topic": "sample_sampling_gear", + "x": 1130, + "y": 220, + "wires": [ + [ + "e17096e4.74caf8" + ] + ] + }, + { + "id": "e046b933.316b28", + "type": "ui_text_input", + "z": "103f6179.d5012f", + "name": "sample_operator", + "label": "Name of the operator", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 6, + "width": 0, + "height": 0, + "passthru": true, + "mode": "text", + "delay": 300, + "topic": "sample_operator", + "x": 1150, + "y": 180, + "wires": [ + [ + "e17096e4.74caf8" + ] + ] + }, + { + "id": "2ff04681.e99aea", + "type": "ui_text_input", + "z": "103f6179.d5012f", + "name": "sample_project", + "label": "Name of the project*", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 1, + "width": 0, + "height": 0, + "passthru": true, + "mode": "text", + "delay": 300, + "topic": "sample_project", + "x": 1160, + "y": 60, + "wires": [ + [ + "e17096e4.74caf8" + ] + ] + }, + { + "id": "75615576.3a38cc", + "type": "ui_text_input", + "z": "103f6179.d5012f", + "name": "sample_id", + "label": "ID of the station*", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 2, + "width": 0, + "height": 0, + "passthru": true, + "mode": "number", + "delay": 300, + "topic": "sample_id", + "x": 1170, + "y": 140, + "wires": [ + [ + "e17096e4.74caf8" + ] + ] + }, + { + "id": "b77eb8b0.a222a8", + "type": "ui_date_picker", + "z": "103f6179.d5012f", + "name": "acq_date", + "label": "Date :", + "group": "aac2eaf7.0cdab8", + "order": 10, + "width": 0, + "height": 0, + "passthru": true, + "topic": "", + "x": 1176, + "y": 640, + "wires": [ + [ + "4fa687df.1aa1d8" + ] + ] + }, + { + "id": "86d5ed81.6dc99", + "type": "ui_text_input", + "z": "103f6179.d5012f", + "name": "acq_time", + "label": "Time :", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 11, + "width": 0, + "height": 0, + "passthru": true, + "mode": "time", + "delay": 300, + "topic": "", + "x": 1176, + "y": 680, + "wires": [ + [ + "26461e30.b461b2" + ] + ] + }, + { + "id": "26461e30.b461b2", + "type": "function", + "z": "103f6179.d5012f", + "name": "set time global", + "func": "var time = new Date(msg.payload);\nglobal.set('generic_acq_time',time);\n\nvar hour = time.getUTCHours();\nif (hour<10){hour = \"0\"+hour;}\nvar minute = time.getUTCMinutes();\nif (minute<10){minute = \"0\"+minute;}\n\nvar time_UTC = \"\"+hour+minute+\"00\";\nglobal.set('object_time',time_UTC);\nreturn msg;", + "outputs": 1, + "noerr": 0, + "x": 1396, + "y": 680, + "wires": [ + [ + "da16d746.4b12e8" + ] + ] + }, + { + "id": "4fa687df.1aa1d8", + "type": "function", + "z": "103f6179.d5012f", + "name": "set date global", + "func": "var date = new Date(msg.payload);\nglobal.set('generic_acq_date',date);\n\nvar year = date.getUTCFullYear();\nvar month = date.getUTCMonth()+1;\nif (month<10){month = \"0\"+month;}\nvar day = date.getUTCDate();\nif (day<10){day = \"0\"+day;}\n\nvar date_UTC = \"\"+year+month+day;\nglobal.set('object_date',date_UTC);\n\nreturn msg;", + "outputs": 1, + "noerr": 0, + "x": 1396, + "y": 640, + "wires": [ + [ + "da16d746.4b12e8" + ] + ] + }, + { + "id": "da16d746.4b12e8", + "type": "function", + "z": "103f6179.d5012f", + "name": "get global", + "func": "msg.payload={\n generic:{\n \"generic_sample_date\":global.get(\"generic_sample_date\"),\n \"generic_sample_time\":global.get(\"generic_sample_time\"),\n \"generic_acq_date\":global.get(\"generic_acq_date\"),\n \"generic_acq_time\":global.get(\"generic_acq_time\")\n },\n sample:{\n \"sample_id\":global.get(\"sample_id\"),\n \"sample_date\":global.get(\"sample_date\"),\n \"sample_time\":global.get(\"sample_time\"),\n \"sample_operator\":global.get(\"sample_operator\"),\n \"sample_project\":global.get(\"sample_project\"),\n \"sample_sampling_gear\":global.get(\"sample_sampling_gear\")\n },\n acquisition:{\n \"acq_id\":global.get(\"acq_id\"),\n \"acq_celltype\":global.get(\"acq_celltype\"),\n \"acq_fnumber_objective\":global.get(\"acq_fnumber_objective\"),\n \"acq_instrument\":global.get(\"acq_instrument\"),\n \"acq_minimum_mesh\":global.get(\"acq_minimum_mesh\"),\n \"acq_maximum_mesh\":global.get(\"acq_maximum_mesh\"),\n \"acq_volume\":global.get(\"acq_volume\"),\n \"acq_magnification\":global.get(\"magnification\")\n },\n object:{\n \"object_date\":global.get(\"object_date\"),\n \"object_time\":global.get(\"object_time\"),\n \"object_depth_min\":global.get(\"object_depth_min\"),\n \"object_depth_max\":global.get(\"object_depth_max\")\n \n },\n process:{\n //PROCESS\n \"process_pixel\":global.get(\"process_pixel\"),\n \"process_id\":global.get(\"process_id\")\n }\n};\nreturn msg;", + "outputs": 1, + "noerr": 0, + "x": 1693, + "y": 60, + "wires": [ + [ + "28df8fd6.06fb7" + ] + ] + }, + { + "id": "6dd1657e.c52e4c", + "type": "file", + "z": "103f6179.d5012f", + "name": "", + "filename": "/home/pi/PlanktonScope/log/config.txt", + "appendNewline": true, + "createDir": true, + "overwriteFile": "true", + "encoding": "none", + "x": 2043, + "y": 60, + "wires": [ + [] + ] + }, + { + "id": "3a43748d.52464c", + "type": "function", + "z": "103f6179.d5012f", + "name": "set optical config", + "func": "global.set(msg.topic,msg.payload);\nvar acq_fnumber_objective = String(global.get(msg.topic));\n\nswitch(acq_fnumber_objective) {\n case \"25\":\n global.set(\"magnification\",0.6);\n global.set(\"process_pixel\",1.86);\n global.set(\"sug_min\",60);\n global.set(\"sug_max\",670);\n global.set(\"sug_flowrate\",3);\n break;\n case \"16\":\n global.set(\"magnification\",0.94);\n global.set(\"process_pixel\",1.19);\n global.set(\"sug_min\",40);\n global.set(\"sug_max\",430);\n global.set(\"sug_flowrate\",2.4);\n break;\n case \"12\":\n global.set(\"magnification\",1.20);\n global.set(\"process_pixel\",0.94);\n global.set(\"sug_min\",30);\n global.set(\"sug_max\",340);\n global.set(\"sug_flowrate\",1.25);\n break;\n case \"8\":\n global.set(\"magnification\",1.78);\n global.set(\"process_pixel\",0.63);\n global.set(\"sug_min\",20);\n global.set(\"sug_max\",230);\n global.set(\"sug_flowrate\",0.42);\n break;\n case \"6\":\n global.set(\"magnification\",2.36);\n global.set(\"process_pixel\",0.48);\n global.set(\"sug_min\",15);\n global.set(\"sug_max\",170);\n global.set(\"sug_flowrate\",0.32);\n break;\n}\nreturn msg;", + "outputs": 1, + "noerr": 0, + "x": 1386, + "y": 720, + "wires": [ + [ + "da16d746.4b12e8" + ] + ] + }, + { + "id": "ff1b2069.b8273", + "type": "ui_dropdown", + "z": "103f6179.d5012f", + "name": "acq_fnumber_objective", + "label": "M12 Lens*", + "tooltip": "", + "place": "Select option", + "group": "aac2eaf7.0cdab8", + "order": 15, + "width": 0, + "height": 0, + "passthru": true, + "options": [ + { + "label": "f 25mm 1/2\" 5MP IR", + "value": 25, + "type": "num" + }, + { + "label": "f 16mm 1/2.5\" 5MP IR", + "value": 16, + "type": "num" + }, + { + "label": "f 12mm 1/2.5\" 5MP IR", + "value": 12, + "type": "num" + }, + { + "label": "f 8mm 1/2.5\" 5MP IR", + "value": 8, + "type": "num" + }, + { + "label": "f 6mm 1/2.5\" 5MP IR", + "value": 6, + "type": "num" + } + ], + "payload": "", + "topic": "acq_fnumber_objective", + "x": 1126, + "y": 720, + "wires": [ + [ + "3a43748d.52464c" + ] + ] + }, + { + "id": "4d38113f.08c6d", + "type": "ui_numeric", + "z": "103f6179.d5012f", + "name": "acq_minimum_mesh", + "label": "Min fraction size (μm)", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 16, + "width": 0, + "height": 0, + "wrap": false, + "passthru": true, + "topic": "acq_minimum_mesh", + "format": "{{value}}", + "min": 0, + "max": "300", + "step": "10", + "x": 1136, + "y": 520, + "wires": [ + [ + "d911efe0.ea7f1" + ] + ] + }, + { + "id": "220c7464.306a8c", + "type": "ui_numeric", + "z": "103f6179.d5012f", + "name": "acq_maximum_mesh", + "label": "Max fraction size (μm)", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 17, + "width": 0, + "height": 0, + "wrap": false, + "passthru": true, + "topic": "acq_maximum_mesh", + "format": "{{value}}", + "min": "200", + "max": "2000", + "step": "100", + "x": 1136, + "y": 560, + "wires": [ + [ + "d911efe0.ea7f1" + ] + ] + }, + { + "id": "c3b1ab59.484178", + "type": "ui_text_input", + "z": "103f6179.d5012f", + "name": "acq_id", + "label": "Acquisition unique ID*", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 9, + "width": 0, + "height": 0, + "passthru": true, + "mode": "number", + "delay": 300, + "topic": "acq_id", + "x": 1186, + "y": 400, + "wires": [ + [ + "d911efe0.ea7f1" + ] + ] + }, + { + "id": "3bb0adb4.de5412", + "type": "ui_dropdown", + "z": "103f6179.d5012f", + "name": "acq_celltype", + "label": "Thickness flowcell*", + "tooltip": "", + "place": "Select option", + "group": "aac2eaf7.0cdab8", + "order": 13, + "width": 0, + "height": 0, + "passthru": true, + "options": [ + { + "label": "200 μm µ-Slide I Luer", + "value": 200, + "type": "num" + }, + { + "label": "400 μm µ-Slide I Luer", + "value": 400, + "type": "num" + }, + { + "label": "600 μm µ-Slide I Luer", + "value": 600, + "type": "num" + }, + { + "label": "800 μm µ-Slide I Luer", + "value": 800, + "type": "num" + } + ], + "payload": "", + "topic": "acq_celltype", + "x": 1166, + "y": 480, + "wires": [ + [ + "d911efe0.ea7f1" + ] + ] + }, + { + "id": "c19a2c73.7512f", + "type": "ui_text_input", + "z": "103f6179.d5012f", + "name": "acq_volume", + "label": "Volume to pass (ml)", + "tooltip": "", + "group": "aac2eaf7.0cdab8", + "order": 14, + "width": 0, + "height": 0, + "passthru": true, + "mode": "number", + "delay": 300, + "topic": "acq_volume", + "x": 1166, + "y": 600, + "wires": [ + [ + "d911efe0.ea7f1" + ] + ] + }, + { + "id": "c9b2c48c.40d068", + "type": "comment", + "z": "103f6179.d5012f", + "name": "sample", + "info": "SAMPLE: a collection event\n\n sample_id [t] : unique identifier\n sample_*** [f] or [t] : other fields relative to the sample\n", + "x": 990, + "y": 20, + "wires": [] + }, + { + "id": "8abc2578.2ebcf8", + "type": "comment", + "z": "103f6179.d5012f", + "name": "acquisition", + "info": "ACQUISITION: metadata relative to the image acquisition\n\n acq_id [t] : unique identifier. If your acquisition differ for each sample you must have different identifier.\n acq_instrument [t] : name of the instrument (UVP, ZOOSCAN, FLOWCAM, etc.)\n acq_*** [f] or [t] : other fields relative to the acquisition\n", + "x": 996, + "y": 360, + "wires": [] + }, + { + "id": "91ab2c80.0f453", + "type": "comment", + "z": "103f6179.d5012f", + "name": "object", + "info": "OBJECT: one object to be classified, usually one organism. One object can be represented by several images. In this tsv file, there is one line per image which means the object data gets repeated on several lines.\n\n object_id [t] : unique object name (will be displayed in Ecotaxa object page)\n object_link [f] : URL of an associated website\n object_lat [f] : latitude, decimal degrees\n object_lon [f] : longitude, decimal degrees\n object_date [f] : ISO8601 YYYYMMJJ UTC\n object_time [f] : ISO8601 HHMMSS UTC\n object_depth_min [f] : minimum depth of object, meters\n object_depth_max [f] : maximum depth of object, meters\n\nAnd, for already classified objects\n\n object_annotation_date [t] : ISO8601 YYYYMMJJ UTC\n object_annotation_time [t] : ISO8601 YYYYMMJJ UTC\n object_annotation_category [t] : class of the object with optionnaly its direct parent following separated by left angle bracket without whitespace \"Cnidaria