/api/replicate

Replicate Pipeline functionality

This API retrieves information on the pipeline status of a scene (or all scenes), and allows commands to be sent to control or reset the pipeline status



Get
/api/replicate?stage=wt3
Endpoint for Wikitude

Returns the virtual WT3 links for all replicate models which have completed the replicate pipeline and are available as meshes
Currently all WT3 files return the same test file data.

Example response:
{

"objects"

:[{

"id"

:509,

"wt3urlrelative"

:

"/api/export?id=509&fmt=wt3"

,

"wr3url"

:

"http://www.replicate3d.eu//api/export?id=509&fmt=wt3"

,

"thumbnail"

:

""

,

"user"

:8},{

"id"

:611,

"wt3urlrelative"

:

"/api/export?id=611&fmt=wt3"

,

"wt3url"

:

"http://www.replicate3d.eu//api/export?id=611&fmt=wt3"

,

"thumbnail"

:

""

,

"user"

:8}]
}






Get
/api/replicate?id={id}
Get information on pipeline status for given scene id

Returns JSON format pipeline status for a scene

Example response:
{
    

"id"

: 1286,
    

"ply_vertex_count"

: 32741,
    

"refined_ply_vertex_count"

: 21858,
    

"poisson_id"

:

"2018:06:27-02:30:49.100-PoissonReconstruction"

,
    

"poisson_start_secs"

: 1530063034.89843,
    

"poisson_end_secs"

: 1530083633.61579,
    

"acquisition_lastdownloadsecs"

: 1530060233.5868,
    

"acquisition_secs"

: 1511521996,
    

"acquisition_url"

:

"/asset/reconstruction/1a40eab0d15a700aa5afe070461792bacfbaa6a78f2ff2a97495406877009bb5"

,
    

"auto_refine"

: true,
    

"image_count"

: 12,
    

"image_download_count"

: 1,
    

"nvm_size"

: 173868
}



Get
/api/replicate?id={id}&stage=ply
Get PLY data from pipeline for given scene

Returns the PLY point cloud file for a scene.
The PLY point cloud is available once ply_vertex_count > 0 in the pipeline status



Get
/api/replicate?id={id}&stage=refined_ply
Get refined PLY data from pipeline for given scene

Returns the refined PLY point cloud file for a scene.
The refined PLY point cloud is available once refined_ply_vertex_count > 0 in the pipeline status



Get
/api/replicate?id={id}&stage=mesh
Get mesh data from pipeline for given scene

Returns the resultant OBJ mesh file for a scene.
The OBJ mesh is available once poisson_end_secs > 0 in the pipeline status



Get
/api/replicate?id={id}&stage=acquisitions
Get acquisition JSON data for given scene

The acquisition JSON data is available once acquisition_secs > 0 in the pipeline status
This is purely for information and not needed to fetch Replicate pipeline model data



Get
/api/replicate?id={id}&stage=images
Get images JSON data for given scene

The images JSON data is available once image_count > 0 in the pipeline status
This is purely for information and not needed to fetch Replicate pipeline model data



Get
/api/replicate?id={id}&stage=nvm
Get NVM data for given scene

The NVM data is available once nvm_size > 0 in the pipeline status
This is purely for information and not needed to fetch Replicate pipeline model data



Get
/api/replicate?id={id}&stage=progress
Get progress percent of pipeline for given scene

Returns as text an integer value indicating the progress percent of the pipeline

>=10 Acquisitions available
>=20 PLY point cloud available
>=30 Refined PLY point cloud available
>=50 Untextured OBJ mesh available (Poisson is complete)
>=60 NVM data is available
>=70 All images downloaded



Post
/api/replicate?id={id}&cmd={cmd}
Send one or more pipeline commands

Commands are separated by spaces (before URL translation)

reset_all forget all pipeline work done for this scene. it will start again.
reset_poisson forget all poisson work for the scene. it will start a new poisson job.
auto_refine 1 turn on auto refining for the point cloud. reset_all should be used afterwards.
auto_refine 0 turn off auto refining for the point cloud. reset_all should be used afterwards.
work do some work for this scene. (ignores queue priorities. will only perform one work step, which may or may not increase the progress in a noticeable percent)