Create Trial
Create trial
post
https://studio.edgeimpulse.com/v1
/api/{projectId}/optimize/{jobId}/create-trial
Create trial
cURL
Python
Node.js
curl --request POST \
--url https://studio.edgeimpulse.com/v1/api/{projectId}/optimize/{jobId}/create-trial \
--header 'content-type: application/json' \
--header 'x-jwt-token: REPLACE_KEY_VALUE' \
--data '{"inputBlock":{"id":0,"title":"string","type":"time-series","dimension":[0],"windowSizeMs":0,"windowIncreasePct":0,"window":{"windowSizeMs":0,"windowIncreaseMs":0},"frequencyHz":0},"dspBlock":{"id":0,"title":"string","type":"spectral-analysis","implementationVersion":0,"channels":"RGB","axes":["string"],"frameLength":0,"numFilters":0,"noiseFloorDb":0,"fftLength":0,"frameStridePct":0},"learnBlock":{"id":0,"title":"string","type":"spectral-analysis","augmentationPolicyImage":"all","augmentationPolicySpectrogram":{},"learningRate":0,"trainingCycles":0,"model":"fomo_mobilenet_v2_a01","dimension":"string","convBaseFilters":0,"convLayers":0,"dropout":0,"denseNeurons":0,"denseBaseNeurons":0,"denseLayers":0,"script":"string","scriptVariables":{},"mode":"string","trainTestSplit":0}}'
import http.client
conn = http.client.HTTPSConnection("studio.edgeimpulse.com")
payload = "{\"inputBlock\":{\"id\":0,\"title\":\"string\",\"type\":\"time-series\",\"dimension\":[0],\"windowSizeMs\":0,\"windowIncreasePct\":0,\"window\":{\"windowSizeMs\":0,\"windowIncreaseMs\":0},\"frequencyHz\":0},\"dspBlock\":{\"id\":0,\"title\":\"string\",\"type\":\"spectral-analysis\",\"implementationVersion\":0,\"channels\":\"RGB\",\"axes\":[\"string\"],\"frameLength\":0,\"numFilters\":0,\"noiseFloorDb\":0,\"fftLength\":0,\"frameStridePct\":0},\"learnBlock\":{\"id\":0,\"title\":\"string\",\"type\":\"spectral-analysis\",\"augmentationPolicyImage\":\"all\",\"augmentationPolicySpectrogram\":{},\"learningRate\":0,\"trainingCycles\":0,\"model\":\"fomo_mobilenet_v2_a01\",\"dimension\":\"string\",\"convBaseFilters\":0,\"convLayers\":0,\"dropout\":0,\"denseNeurons\":0,\"denseBaseNeurons\":0,\"denseLayers\":0,\"script\":\"string\",\"scriptVariables\":{},\"mode\":\"string\",\"trainTestSplit\":0}}"
headers = {
'content-type': "application/json",
'x-jwt-token': "REPLACE_KEY_VALUE"
}
conn.request("POST", "/v1/api/{projectId}/optimize/{jobId}/create-trial", payload, headers)
res = conn.getresponse()
data = res.read()
print(data.decode("utf-8"))
const request = require('request');
const options = {
method: 'POST',
url: 'https://studio.edgeimpulse.com/v1/api/{projectId}/optimize/{jobId}/create-trial',
headers: {'content-type': 'application/json', 'x-jwt-token': 'REPLACE_KEY_VALUE'},
body: {
inputBlock: {
id: 0,
title: 'string',
type: 'time-series',
dimension: [0],
windowSizeMs: 0,
windowIncreasePct: 0,
window: {windowSizeMs: 0, windowIncreaseMs: 0},
frequencyHz: 0
},
dspBlock: {
id: 0,
title: 'string',
type: 'spectral-analysis',
implementationVersion: 0,
channels: 'RGB',
axes: ['string'],
frameLength: 0,
numFilters: 0,
noiseFloorDb: 0,
fftLength: 0,
frameStridePct: 0
},
learnBlock: {
id: 0,
title: 'string',
type: 'spectral-analysis',
augmentationPolicyImage: 'all',
augmentationPolicySpectrogram: {},
learningRate: 0,
trainingCycles: 0,
model: 'fomo_mobilenet_v2_a01',
dimension: 'string',
convBaseFilters: 0,
convLayers: 0,
dropout: 0,
denseNeurons: 0,
denseBaseNeurons: 0,
denseLayers: 0,
script: 'string',
scriptVariables: {},
mode: 'string',
trainTestSplit: 0
}
},
json: true
};
request(options, function (error, response, body) {
if (error) throw new Error(error);
console.log(body);
});
Export as PDF
Copy link