⬆️ Upload annotations

If you'd like to share your annotations to Panoramax, you can use the annotations_*.geojson files which were generated by the prolix run-model-* commands. To do so, run:

prolix upload-annotations \
    --api-url https://panoramax.ign.fr \
    --token myverylongusertoken \
    /path/to/model/results/annotations.geojson

Note that annotations upload works for any kind of annotated pictures, not only the ones generated by Prolix. You have to follow this GeoJSON format for it to work:

{
  "type": "FeatureCollection",
  "features": [
    {
      "type": "Feature",
      /* Geometry is not used by Prolix, it can correspond to picture coordinates */
      "geometry": {
        "coordinates": [5.424,43.527],
        "type": "Point"
      },
      "properties": {
        /* Panoramax picture UUID */
        "pnx_pic_uuid": "76a61e41-1dbc-417e-af71-537d884b95aa",
        /* Panoramax server where the picture is hosted */
        "pnx_instance": "https://panoramax.ign.fr",
        /* The annotation to create, one per feature */
        "pnx_annotation": {
        /* List of key/values in same format as Panoramax API */
        "semantics": [
          { "key": "osm|traffic_sign", "value": "yes", "action": "delete" },
          { "key": "osm|traffic_sign", "value": "FR:C20a" },
          ...
        ],
        /*
          Annotation position in image, as [minx, miny, maxx, maxy]
          or a "Polygon" shape as expected by Panoramax API
        */
        "shape": [ 1152, 1344, 1216, 1424 ]
      },
      ...
      }
    },
    ...
  ]
}