A TypeError: 'int' object is not subscriptable occurs when running the locomotion branch during the sampling phase.