Skip to content

NevarokML: UNevarokMLNNEModel API

The UNevarokMLNNEModel acts as a bridge, facilitating the combination of NevarokML's machine learning capabilities with the powerful Unreal Engine Neural Network Engine. By leveraging the UNevarokMLNNEModel, you can seamlessly integrate trained neural network models into your Unreal Engine projects, unlocking advanced AI and machine learning functionalities.


Properties

  • _cpuModel (TSharedPtr<UE::NNECore::IModelCPU>): The CPU model for the neural network.
  • _actSample (UNevarokMLSample): The action sample for the neural network model.
  • _obsSample (UNevarokMLSample): The observation sample for the neural network model.
  • _inputTensors (TArray<FNevarokMLNNETensor>): The input tensors for the neural network.
  • _outputTensors (TArray<FNevarokMLNNETensor>): The output tensors for the neural network.
  • _inputBindings (TArray<UE::NNECore::FTensorBindingCPU>): The input bindings for the neural network model.
  • _outputBindings (TArray<UE::NNECore::FTensorBindingCPU>): The output bindings for the neural network model.

Methods

IsValid

UFUNCTION(BlueprintPure, Category = "NevarokML|NNEModel")
bool UNevarokMLNNEModel::IsValid() const;
Checks if the neural network model is valid.

Predict

UFUNCTION(BlueprintCallable, Category = "NevarokML|NNEModel")
bool UNevarokMLNNEModel::Predict();
Runs the neural network model prediction and update the action sample based on the observation sample data.

NNEModel

UFUNCTION(BlueprintPure, Category = "NevarokML|NNEModel")
static UNevarokMLNNEModel* UNevarokMLNNEModel::NNEModel(UObject* owner, UNNEModelData* modelData, UNevarokMLSample* actSample, UNevarokMLSample* obsSample);
Creates a new instance of the UNevarokMLNNEModel class.