-
Notifications
You must be signed in to change notification settings - Fork 40
Commit
- Loading branch information
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#include "binding_static_model.h" | ||
|
||
using namespace rl_net_native; | ||
|
||
binding_static_model::binding_static_model(const std::vector<std::byte>& model_weights) : weights(model_weights) { | ||
} | ||
|
||
int binding_static_model::get_data(reinforcement_learning::model_management::model_data& data, reinforcement_learning::api_status* status) { | ||
data.set_data(weights.data(), weights.size()); | ||
|
||
return error_code::success; | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,12 @@ | ||
#include <vector> | ||
|
||
namespace rl_net_native { | ||
class binding_static_model : public reinforcement_learning::model_management::i_data_transport { | ||
Check failure on line 4 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 4 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 4 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 4 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 4 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / Analyze CSharp bindings
|
||
public: | ||
binding_static_model(const std::vector<std::byte>& model_weights); | ||
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / Analyze CSharp bindings
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / Analyze CSharp bindings
Check failure on line 6 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / Analyze CSharp bindings
|
||
int get_data(reinforcement_learning::model_management::model_data& data, reinforcement_learning::api_status* status = nullptr) override; | ||
Check failure on line 7 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 7 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 7 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 7 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 7 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / Analyze CSharp bindings
|
||
|
||
private: | ||
std::vector<std::byte> weights; | ||
Check failure on line 10 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 10 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-debug-windows-latest
Check failure on line 10 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 10 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / rlclientlib-release-windows-latest
Check failure on line 10 in bindings/cs/rl.net.native/binding_static_model.h GitHub Actions / Analyze CSharp bindings
|
||
}; | ||
} |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,6 @@ | ||
using System; | ||
using System.Runtime.InteropServices; | ||
using System.Collections.Generic; | ||
|
||
using Rl.Net.Native; | ||
|
||
|