MIT-REALM / neural_clbf

Toolkit for learning controllers based on robust control Lyapunov barrier functions
BSD 3-Clause "New" or "Revised" License
117 stars 40 forks source link

Generate_Random_Reference x_init confusion #28

Open Ac31415 opened 2 weeks ago

Ac31415 commented 2 weeks ago

Hi, thank you for releasing this research work! I have a question regarding how the generate_random_reference is implemented in the simulation.py file under the "contraction" directory. The method is supposed to output x_init, which is a tensor of initial states according to your comments. However near the end of the method, I'm seeing you're adding random errors to those initial states, which should have been the beginning of the reference trajectories. If I plot the x_ref along with the x_init as its beginning, one of the reference trajectories looked like the following:

imageData-95

Any reasons why the random errors are added to the x_init tensor that's causing the discontinuity between the x_init and the rest of the x_ref?

Ac31415 commented 2 weeks ago

Never mind, I think I understood it now. The x_init is meant to be used by the "simulation" method. Is that why the x_init is randomized?