| src | ||
| .DS_Store | ||
| Cargo.lock | ||
| Cargo.toml | ||
| example_input.json | ||
| README.md | ||
ILI comparison (compare all)
This function will run all possible ILI comparisons for a given pipeline using the continuous scorer implementation.
See ILI comparison for more details of the comparison algorithm.
Input
Arguments
org_id: as string which should be a validuuidfor the organizationproject_id: the id of the data project where the pipeline data is foundpipeline_id: aarrayof string values representing a validuuidfor a pipelineolder_ili_id: aarrayof string values representing a validuuidfor an ili report sequencenewer_ili_id: aarrayof string values representing a validuuidfor an ili report sequenceweld_location_threshold: afloatvaluefeature_location_threshold: afloatvalueupstream_girth_threshold: afloatvalueorientation_threshold: afloatvalueanomaly_size: anobjectwith the configuration for the depth and length of the anomaliessurface_location_criteria: astringwhose value should be one ofmatchingany
Creating the function on the platform
To create this function on the platform using the cli set up the port forwarding as shown in README.
Then run the following command to create the function.
cargo run functions create \
-f functions/ili_compare_all_continuous \
-d "Runs the ILI comparison algorithm for all combinations of ILI reports for the given pipeline using the continuous scorer" \
-o org_id=string \
-o project_id=string \
-o pipeline_ids=array \
-o matched_ids=array \
-o unmatched_ids=array \
-o summary_ids=array \
-i org_id=string \
-i project_id=string \
-i pipeline_id=array \
-i older_ili_id=array \
-i newer_ili_id=array \
-i weld_location_threshold=float \
-i upstream_girth_threshold=float \
-i feature_location_threshold=float \
-i orientation_threshold=float \
-i anomaly_size=object \
-i surface_location_criteria=string
Testing the function locally
You can run and test the function locally by running
cargo run
Then you can check it work with curl as follows
curl localhost:8080 -d $(jq '. | tojson' functions/ili_compare_all_continuous/example_input.json)