Get processed sample (from features array)

Get processed sample (from features array)

post

Takes in a features array and runs it through the DSP block. This data should have the same frequency as set in the input block in your impulse.

Authorizations
Path parameters
projectIdintegerRequired

Project ID

dspIdintegerRequired

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

Body
featuresinteger[]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]).

drawGraphsbooleanRequired

Whether to generate graphs (will take longer)

requestPerformancebooleanRequired

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

Responses
200
OK
application/json
Responseall of
post
POST /v1/api/{projectId}/dsp/{dspId}/run HTTP/1.1
Host: studio.edgeimpulse.com
x-api-key: YOUR_API_KEY
Content-Type: application/json
Accept: */*
Content-Length: 89

{
  "features": [
    1
  ],
  "params": {
    "scale-axes": "10"
  },
  "drawGraphs": true,
  "requestPerformance": true
}
200

OK

{
  "success": true,
  "error": "text",
  "features": [
    1
  ],
  "graphs": [
    {
      "name": "Frequency domain",
      "image": "text",
      "imageMimeType": "text",
      "X": {
        "accX": [
          3,
          5,
          7
        ],
        "accY": [
          2,
          1,
          5
        ]
      },
      "y": [
        0,
        0.5,
        1
      ],
      "suggestedXMin": 1,
      "suggestedXMax": 1,
      "suggestedYMin": 1,
      "suggestedYMax": 1,
      "type": "text",
      "lineWidth": 1,
      "smoothing": true,
      "axisLabels": {
        "X": "text",
        "y": "text"
      },
      "highlights": {
        "ANY_ADDITIONAL_PROPERTY": [
          1
        ]
      }
    }
  ],
  "labels": [
    "text"
  ],
  "state_string": "text",
  "performance": {
    "latency": 1,
    "ram": 1,
    "customDspString": "text"
  }
}

Last updated

Was this helpful?