フィルターのクリア

Subscripted assignment between dissimilar structures

9 ビュー (過去 30 日間)
Zaid Jaber
Zaid Jaber 2023 年 10 月 26 日
編集済み: Zaid Jaber 2023 年 11 月 10 日
Hello everyone
I am using rlDDPG to train an a robot, I tried the training before and everything was going fine, I started a new training and I keep getting the following error ... any ideas?
Subscripted assignment between dissimilar structures.
Error in rl.replay.internal.InMemoryReplay/append_ (line 50)
obj.Memory_(selectedIdx, 1) = Experiences;
Error in rl.replay.internal.AbstractInternalReplayMemory/append (line 31)
append_(obj,Experiences,DataSourceID);
Error in rl.replay.rlReplayMemory/appendWithoutSampleValidation (line 319)
append(obj.InternalReplayMemory_,Experiences,DataSourceID);
Error in rl.agent.AbstractOffPolicyAgent/appendExperiencesToMemory_ (line 196)
appendWithoutSampleValidation(this.ExperienceBuffer,experiences);
Error in rl.agent.mixin.InternalMemoryTrainable/appendExperiencesToMemory (line 27)
appendExperiencesToMemory_(this,experiences);
Error in rl.train.parallel.ExpAsyncParallelTrainer/processSimOutput_ (line 57)
appendExperiencesToMemory(this.Agent,experiences);
Error in rl.train.parallel.AsyncParallelTrainer/processFutures_ (line 28)
processSimOutput_(this,out);
Error in rl.train.parallel.AbstractParallelTrainer/run (line 70)
[F,outs,taskIDs] = processFutures_(this,F);
Error in rl.train.TrainingManager/train (line 516)
run(trainer);
Error in rl.train.TrainingManager/run (line 253)
train(this);
Error in rl.agent.AbstractAgent/train (line 187)
trainingResult = run(trainMgr,checkpoint);
  4 件のコメント
Zaid Jaber
Zaid Jaber 2023 年 11 月 10 日
@Emmanouil Tzorakoleftherakis Sorry for the late reply, it was a new training, after I restarted matlab, it worked!
Thank you
Zaid Jaber
Zaid Jaber 2023 年 11 月 10 日
@Walter Roberson Thanks it worked after I restrarted matlab

サインインしてコメントする。

採用された回答

Garmit Pant
Garmit Pant 2023 年 11 月 6 日
Hello Zaid
I understand that you are trying to train a robot using an ‘rlDDPG’ agent but on the second run of the training, you are encountering an error.
As stated by Walter in the comments, the error means that the ‘Experiences’ property of the simulated output ‘Future’ does not match the expected structure which should have the following fields: ‘Observation,Action, Reward, NextObservation and IsDone’.
After investigating the error message, the error can be originating due to different reasons based on which of the following cases is applicable to your use case.
  • 1) You are using pretrained checkpoints:
  • If you are using pretrained checkpoints from the previous training run, either the checkpoints are not loaded correctly or not stored properly. This is so because the function ‘run’ is running the ‘train’ method and not the ‘preTrain’ method which should be the case when pretrained checkpoints are used.
  • 2) You are not using pretrained checkpoints:
  • Please check the ‘environment’, ‘agents’,opt’ and ‘evaluator’ arguments that you are passing while defining ‘trainMgr’ object. They are responsible for the simulation of futures and the calculation of experiences.
I hope this helps!
Best Regards
Garmit
  1 件のコメント
Zaid Jaber
Zaid Jaber 2023 年 11 月 10 日
編集済み: Zaid Jaber 2023 年 11 月 10 日
can that be solved by restarting matlab, this is what i did and it works, it was a new training

サインインしてコメントする。

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeGPU Computing についてさらに検索

タグ

製品


リリース

R2023b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by