POST
/
api
/
{projectId}
/
dsp
/
{dspId}
/
run
Get processed sample (from features array)
curl --request POST \
  --url https://studio.edgeimpulse.com/v1/api/{projectId}/dsp/{dspId}/run \
  --header 'Content-Type: application/json' \
  --header 'x-api-key: <api-key>' \
  --data '{
  "features": [
    123
  ],
  "params": {
    "scale-axes": "10"
  },
  "drawGraphs": true,
  "requestPerformance": true
}'
{
  "success": true,
  "error": "<string>",
  "features": [
    123
  ],
  "graphs": [
    {
      "name": "Frequency domain",
      "image": "<string>",
      "imageMimeType": "<string>",
      "X": {
        "accX": [
          3,
          5,
          7
        ],
        "accY": [
          2,
          1,
          5
        ]
      },
      "y": [
        0,
        0.5,
        1
      ],
      "suggestedXMin": 123,
      "suggestedXMax": 123,
      "suggestedYMin": 123,
      "suggestedYMax": 123,
      "type": "<string>",
      "lineWidth": 123,
      "smoothing": true,
      "axisLabels": {
        "X": "<string>",
        "y": "<string>"
      },
      "highlights": {}
    }
  ],
  "labels": [
    "<string>"
  ],
  "state_string": "<string>",
  "performance": {
    "latency": 123,
    "ram": 123,
    "customDspString": "<string>"
  }
}

Authorizations

x-api-key
string
header
required

Path Parameters

projectId
integer
required

Project ID

dspId
integer
required

DSP Block ID, use the impulse functions to retrieve the ID

Body

application/json
features
integer[]
required

Array of features. If you have multiple axes the data should be interleaved (e.g. [ax0_val0, ax1_val0, ax2_val0, ax0_val1, ax1_val1, ax2_val1]).

params
object
required

DSP parameters with values

Example:
{ "scale-axes": "10" }
drawGraphs
boolean
required

Whether to generate graphs (will take longer)

requestPerformance
boolean
required

Whether to request performance info (will take longer unless cached)

Response

200 - application/json

OK

success
boolean
required

Whether the operation succeeded

features
number[]
required

Array of processed features. Laid out according to the names in 'labels'

graphs
object[]
required

Graphs to plot to give an insight in how the DSP process ran

error
string

Optional error description (set if 'success' was false)

labels
string[]

Labels of the feature axes

state_string
string

String representation of the DSP state returned

performance
object