33 lines
651 B
33 lines
651 B
7 years ago
|
#ifndef MONITORING_H
|
||
|
#define MONITORING_H
|
||
|
|
||
|
#include "commonmodel.h"
|
||
6 years ago
|
#include "runners/run.h"
|
||
7 years ago
|
|
||
|
#ifdef __cplusplus
|
||
|
extern "C" {
|
||
|
#endif
|
||
|
|
||
6 years ago
|
#define OUTPUT_SIZE 8
|
||
7 years ago
|
|
||
|
typedef struct MonitoringResult {
|
||
6 years ago
|
float vs[OUTPUT_SIZE - 1];
|
||
7 years ago
|
float std;
|
||
|
} MonitoringResult;
|
||
|
|
||
|
typedef struct MonitoringState {
|
||
|
ModelInput in;
|
||
6 years ago
|
RunModel *m;
|
||
7 years ago
|
float output[OUTPUT_SIZE];
|
||
|
} MonitoringState;
|
||
|
|
||
|
void monitoring_init(MonitoringState* s, cl_device_id device_id, cl_context context);
|
||
|
MonitoringResult monitoring_eval_frame(MonitoringState* s, cl_command_queue q, cl_mem yuv_cl, int width, int height);
|
||
|
void monitoring_free(MonitoringState* s);
|
||
|
|
||
|
#ifdef __cplusplus
|
||
|
}
|
||
|
#endif
|
||
|
|
||
|
#endif
|