huggingface / lerobot

🤗 LeRobot: Making AI for Robotics more accessible with end-to-end learning
Apache License 2.0
6.54k stars 582 forks source link

Seeking advice on how to choose between ACT and DP algorithms #263

Closed le-wei closed 3 months ago

le-wei commented 3 months ago

Hello,

Thank you very much for the work you have done in bringing together the current excellent imitation learning collections for convenient use. Regarding the ACT algorithm and DP algorithm, besides the basic differences in the algorithms themselves, how should one choose between them for different tasks? Do they have specific types of tasks they are particularly suited for? I have just started using your project and am unsure how to select the appropriate algorithm. I would greatly appreciate any advice you can provide.

Thank you!

alexander-soare commented 3 months ago

Hi @le-wei, thanks for the props! Here are some of my answers (but I think that for some of these you'll get different answers depending on who you ask)

le-wei commented 3 months ago

@alexander-soare Thank you very much for your response, it has been incredibly helpful. I can prioritize trying one approach in practice. Thank you again for your guidance.In practice, we also found that ACT is indeed less flexible than DP. However, ACT learns certain details better than DP, such as control over angles and distances. Do you have any good suggestions or methods to improve the flexibility of ACT? Our attempts to enhance images or add small amounts of noise to the trajectories have not yielded satisfactory results.

alexander-soare commented 3 months ago

@le-wei thanks for the tidbits!

When you say "improve the flexibility of ACT" can I check what you mean exactly? I think by "enhance images and add small amounts of noise" it seems you are referring to test-time generalization? We do have a new data augmentation feature which we have experimentally been shown to improve results https://github.com/huggingface/lerobot/pull/234

le-wei commented 3 months ago

"Thank you very much for your advice, I have learned a lot from your suggestions." @alexander-soare

le-wei commented 3 months ago

"Have you considered standardizing the data representation in ACT and DP? This way, the generated dataset can adapt to both strategies without requiring significant code modifications." ACT: image DP: image

alexander-soare commented 3 months ago

@le-wei it's not well documented yet, but this is part of the "standard" format. We allow "observation.image" if there is one image. If there is more than one image we require "observation.images.x", "observation.images.y" etc. It's an experiment and we will be more careful about documenting it once we think it's the way to go. Does that help answer your question?

le-wei commented 3 months ago

Thank you very much for your patient explanation. @alexander-soare

alexander-soare commented 3 months ago

Great, well, I'll close this issue and you're more than welcome to reopen if it's not resolved or open another one.