Wrong suming output in simulink r2023A
조회 수: 1 (최근 30일)
이전 댓글 표시
Greetings!
We are training a reinforcement learning agent using the R2023a version in Ubuntu 22.04 LTS. We have built a reward block that should result in a reward value of -150 when the input is under a particular range. We have observed that the input to the summing block in the reward function is of value -150 (-100, -50, 0, 0) while the output of the sum block is of value 106
When we tested with constant values, as shown in the attached image, the sum block resulted in a value of -150, as intended.
This has affected the training of agents drastically.
댓글 수: 0
답변 (1개)
Steven Lord
2024년 4월 6일
I don't work with Simulink that much, but I'd check the data types of the various signals in your code.
106 - (-150)
The fact that these two numbers differ by a power of 2 makes me suspicious that there's some conversion with wrapping going on.
댓글 수: 0
참고 항목
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!