tkn-tub / ns3-gym

ns3-gym - The Playground for Reinforcement Learning in Networking Research
GNU General Public License v2.0
521 stars 197 forks source link

Difference between TimeBasedTcp and EventBasedTcp in example/rltcp? #13

Closed hexi519 closed 5 years ago

hexi519 commented 5 years ago

Still can not figure out differences between TimeBasedTcp and EventBasedTcp in example/rltcp, which seems no materials I can refer to?

pgawlowicz commented 5 years ago

Hi,

In the TcpTimeStepGymEnv the state of TCP is reported in equal time steps, as the Notify() function is scheduled periodically: https://github.com/tkn-tub/ns3-gym/blob/master/scratch/rl-tcp/tcp-rl-env.cc#L422-L428

While in the TcpEventGymEnv the Notify() function is executed every time the TCP instance tries to access or change its internal state.

Best, Piotr

hexi519 commented 5 years ago

Thanks !