#include "wrapper.h"
#include "include/Beatmup_NNets_AbstractOperation.h"
#include "include/Beatmup_NNets_DeserializedModel.h"
#include "include/Beatmup_NNets_InferenceTask.h"
#include "include/Beatmup_NNets_ImageSampler.h"
#include "include/Beatmup_NNets_Model.h"
#include "include/Beatmup_NNets_Softmax.h"
#include "android/context.h"
#include <core/nnets/deserialized_model.h>
#include <core/nnets/inference_task.h>
#include <iostream>
#include <sstream>
Go to the source code of this file.
|
| BEATMUP_OBJ (Beatmup::NNets::Model, model, handle) |
|
return jenv | NewStringUTF (model->serializeToString().c_str()) |
|
| return (jlong) model -> countMultiplyAdds() |
|
| BEATMUP_OBJ (Beatmup::Android::Context, ctx, jCtx) |
|
| BEATMUP_STRING (str) |
|
| BEATMUP_CATCH ({ auto model=new Beatmup::NNets::DeserializedModel(*ctx, strStr); $pool.addJavaReference(jenv, jCtx, model);return(jlong) model;}) |
|
| BEATMUP_OBJ (Beatmup::NNets::AbstractOperation, op, handle) |
|
return jenv | NewStringUTF (op->getName().c_str()) |
|
| BEATMUP_STRING (name) |
|
| catch (Beatmup::InvalidArgument &ex) |
|
| BEATMUP_OBJ (Beatmup::NNets::Softmax, softmax, handle) |
|
| for (size_t i=0;i< proba.size();++i) outptr[i] |
|
jenv | ReleaseFloatArrayElements (result, outptr, 0) |
|
| BEATMUP_OBJ (Beatmup::NNets::ImageSampler, imageSampler, handle) |
|
imageSampler | setRotation ((int) rotation) |
|
| return (jint) imageSampler -> getRotation() |
|
| BEATMUP_OBJ (Beatmup::NNets::Model, model, jModel) |
|
| BEATMUP_OBJ (Beatmup::ChunkCollection, data, jData) |
|
$pool | addJavaReference (jenv, jModel, task) |
|
$pool | addJavaReference (jenv, jData, task) |
|
| BEATMUP_OBJ (Beatmup::NNets::InferenceTask, task, handle) |
|
| BEATMUP_OBJ (Beatmup::AbstractBitmap, bitmap, jBitmap) |
|
| BEATMUP_STRING (opName) |
|
| BEATMUP_OBJ (Beatmup::NNets::AbstractOperation, op, hOp) |
|
task connect * | bitmap (int) index |
|
◆ BEATMUP_OBJ() [1/10]
◆ NewStringUTF() [1/2]
return jenv NewStringUTF |
( |
model-> |
serializeToString).c_str( | ) |
|
◆ return() [1/2]
return |
( |
jlong |
| ) |
-> countMultiplyAdds() |
◆ BEATMUP_OBJ() [2/10]
◆ BEATMUP_STRING() [1/3]
◆ BEATMUP_CATCH()
◆ BEATMUP_OBJ() [3/10]
◆ NewStringUTF() [2/2]
◆ BEATMUP_STRING() [2/3]
◆ catch()
Definition at line 124 of file wrapper_nnets.cpp.
static void throwToJava(JNIEnv *jenv, const char *exceptionClass, const char *message)
Throws a specific exception.
virtual const char * what() const NOEXCEPT override
BeatmupJavaObjectPool $pool
◆ BEATMUP_OBJ() [4/10]
◆ for()
Definition at line 132 of file wrapper_imag.cpp.
Abstract scene layer having name, type, geometry and some content to display.
#define BEATMUP_DELETE_REFERENCE(obj)
return $pool getJavaReference & scene(index)
◆ ReleaseFloatArrayElements()
◆ BEATMUP_OBJ() [5/10]
◆ setRotation()
imageSampler setRotation |
( |
(int) |
rotation | ) |
|
◆ return() [2/2]
return |
( |
jint |
| ) |
-> getRotation() |
◆ BEATMUP_OBJ() [6/10]
◆ BEATMUP_OBJ() [7/10]
◆ addJavaReference() [1/2]
◆ addJavaReference() [2/2]
◆ BEATMUP_OBJ() [8/10]
◆ BEATMUP_OBJ() [9/10]
◆ BEATMUP_STRING() [3/3]
◆ BEATMUP_OBJ() [10/10]
◆ bitmap()
task connect* bitmap |
( |
int |
| ) |
|
◆ jenv
◆ jobject
◆ handle
◆ jclass
◆ jCtx
◆ str
◆ name
JNIEnv jlong jstring name |
◆ try
◆ proba
const auto& proba = softmax->getProbabilities() |
◆ result
◆ outptr
jfloat* outptr = jenv->GetFloatArrayElements(result, nullptr) |
◆ rotation
JNIEnv jlong jint rotation |
◆ jModel
◆ jData
◆ task
◆ jBitmap
◆ opName
◆ index
◆ hOp