question

Marisol avatar image
0 Likes"
Marisol asked Julie Weller commented

Reinforcement Learning Model

Hello good day, I want to start configuring models with the Reinforcement Learning module, I am working with the following model (attached model). In general with this model is to generate a learning between the movement of two cars, with respect to the distance that exist between them.

AI_Car_movement_test_v02.fsm

Questions:

1. I have doubt in the "On Request Action" section. I put the option "Query a Server an Action", I get this error:

1686684132150.png

2. In the "Query a Server an Action" option, should I modify the host or port or should I leave it like that?

1686684143405.png

3. Do you have any kind of documentation of how each of the three options works, to know which one to choose, which is the optimal one, depending on the use case.

1686684151974.png


FlexSim 23.1.1
reinforcement learningerrorsconfigurationmodel documentation
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

1 Answer

Julie Weller avatar image
0 Likes"
Julie Weller answered Julie Weller commented

One of the best resources for using reinforcement learning is this tutorial and other resources on the docs site. In that tutorial it states this:

"In the On Request Action trigger, add the option to Take a Random Action.

  • The On Request Action trigger fires when the model is run normally, not in training mode. For now, we will have the model take random actions when run normally."

So you would the Query A Server action to allow an AI you've already trained to show how they use the model and let them take actions.

The default host is to the FlexSim webserver which is were the link to http://127.0.0.1/, however if you aren't hosting that server it won't connect. You can learn more about that at this link. Does that help answer your question and give you enough to start?

· 2
5 |100000

Up to 12 attachments (including images) can be used with a maximum of 23.8 MiB each and 47.7 MiB total.

Marisol avatar image Marisol commented ·

Hello,

Yes I have been following this tutorial and I had good results, I didn´t have problems with that example. However when I want to implement more complex things I lack information. I wonder if soon you will put more advanced examples?

I have it enabled for adding a random action, yes I have it enabled. I will check the documentation about the server configuration.

0 Likes 0 ·
Julie Weller avatar image Julie Weller Marisol commented ·

Yeah I think that would be the best idea is check the documentation. There's some more examples of Reinforcement learning models for FlexSim at this link: https://github.com/flexsim/ai-course-materials

As for adding new and more advanced examples, I'm not sure if they're going to upload new models soon but with time the answers site should have more and more good examples as people try out that feature more often. Sorry that's not more helpful!

0 Likes 0 ·