Running the package “Quanser QUBE-Servo 2 Pendulum Control Reinforcement Learning” causes an error when extracting the policy from the agent
13 views (last 30 days)
Show older comments
I downloaded and ran the “Quanser QUBE-Servo 2 Pendulum Control Reinforcement Learning” package.
Learning was successful, but an error occurred in the part where the policy is extracted from the agent.
The error is that the policy is missing.
In the meantime, I would like you to download this package and try it out.
And please let me know how to solve this error.
We look forward to hearing from you!
Quanser QUBE-Servo 2 Pendulum Control Reinforcement Learning
Shows how to design a reinforcement learning agent to balance the Quanser QUBE-Servo 2 Inverted Pendulum.
% Load pre-defined policy (false) or generate new policy for RT code gen (true)
% doPolicy = false;
doPolicy = true;
%
if doPolicy
% Generate policy for deployment
generatePolicyFunction(agent,'MATFileName','QubeIPBalRLPolicy.mat');
load("QubeIPBalRLPolicy.mat");
policy = cut_unnecessary_layers_for_SAC_policy(policy);
save("QubeIPBalRLPolicy.mat", 'policy');
else
% Load previously saved policy
load("QubeIPBalRLPolicy.mat");
end
0 Comments
Answers (0)
See Also
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!