Skip to content

Pre-publication code review #368

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 382 commits into
base: sampling_based_c3_public
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
382 commits
Select commit Hold shift + click to select a range
3c73727
Added c3 final target input port and visualization changes.
sharanyashastry Sep 6, 2024
ac7d628
Added verbosity flag in controller along with verbose prints.
sharanyashastry Sep 7, 2024
85fde4e
Setup the lcm log loader for the sampling controller. This binary wil…
sharanyashastry Sep 7, 2024
ecec2e8
-Cleaned up log loader to read cmd line argument for log path.
sharanyashastry Sep 7, 2024
4f9c547
Include world-frame witness points as printouts in verbose mode
sharanyashastry Sep 7, 2024
7c60949
Dumping the single state controllergit status
sharanyashastry Sep 7, 2024
83483e4
-Added a straight line trajectory for the repositioning to follow whe…
sharanyashastry Sep 8, 2024
1ab269b
Fix abort bug when setting number of samples to 0, caused by repositi…
sharanyashastry Sep 8, 2024
5deb391
Pushing params before hardware experiments.
sharanyashastry Sep 8, 2024
a204604
Fixed bug in control target generator for converting quaternion erro…
sharanyashastry Sep 9, 2024
2d7efb4
Revert to angular velocity conversion from quaternion errors (prior c…
ebianchi Sep 10, 2024
789a555
Add in ability to scale angular velocity goal resuling from quaternio…
sharanyashastry Sep 10, 2024
2e4b000
New way of processing contacts. Update log_loader accordingly. Jack g…
sharanyashastry Sep 11, 2024
5f457f7
Lcm log loader now reads the dynamically feasible orientation plan as…
sharanyashastry Sep 11, 2024
5a7c7a6
- Use 6 contact lcs based on the use_more_contacts_to_compute_cost fl…
sharanyashastry Sep 12, 2024
043b960
Removed full_diagram
sharanyashastry Sep 13, 2024
a9c28df
Rolled back the change on c3_curr_plan_ that tried to have the curren…
sharanyashastry Sep 25, 2024
f7fe9c4
Changed the ee min-z constraint to start from the first time step ins…
sharanyashastry Sep 25, 2024
c303e77
Added a collision geometry for the cylindrical portion of the end eff…
sharanyashastry Sep 25, 2024
d638de5
Forcing controller to set the outputport information using Forced dis…
sharanyashastry Sep 25, 2024
205783c
Minimal print statement change in c3.cc
sharanyashastry Sep 27, 2024
506ffd5
Debugging timing issue: print statements within lcm loop. Also cleane…
sharanyashastry Oct 1, 2024
d13bf0e
WIP changes for adding changing end goals for the object.
sharanyashastry Oct 1, 2024
da020f8
Matching the repositioning prediction to how it is done in c3 mode.
sharanyashastry Oct 1, 2024
8e6d3cb
Log loader now prints all traacking traj output messages along with t…
sharanyashastry Oct 2, 2024
0f7d5b8
update lcm driven loop to use most recent message
Brian-Acosta Oct 3, 2024
6416507
Added python scripts for processing log information and console infor…
sharanyashastry Oct 7, 2024
4c00dc5
LCM buffer bug fix: The lcm buffer used to be a queue of depth 1 that…
sharanyashastry Oct 7, 2024
dd9935e
Removing print statements from sampling controller.
sharanyashastry Oct 7, 2024
8561d22
Initial working set of params for orientation only. Look at logs from…
sharanyashastry Oct 14, 2024
b7b821a
Modified clamping code to have the approx loop time bounded by 0.1s. …
sharanyashastry Oct 14, 2024
d7932b7
Preliminary params for position and orientation tracking!
sharanyashastry Oct 14, 2024
75b6974
Draft quaternion angle error hessian, not yet incorporated into contr…
ebianchi Oct 16, 2024
3b4eb5c
Scripts for computing hessian of squared angle between two quaternions
ebianchi Oct 21, 2024
4c94fcf
Added functionality to include cost = hessian of quaternion angle err…
sharanyashastry Oct 22, 2024
b4262d5
Include regularization on quaternion errors to avoid NSD issues
ebianchi Oct 23, 2024
5f6be3f
Use quaternion-dependent orientation cost only after crossed switchin…
sharanyashastry Oct 25, 2024
14aa4a6
Use quaternion dependent cost regularizer to enforce PSD
sharanyashastry Oct 28, 2024
711952a
Changes to be able to use relative cost in place of absolute costs fo…
sharanyashastry Oct 28, 2024
c5751b5
Removed print from controller.
sharanyashastry Oct 29, 2024
4e175f7
Changes to normalize the quaternion since Eigen doesn't handle this w…
sharanyashastry Oct 29, 2024
eeaa89b
Pushing parameters tested across 4 scenarios for orientation only usi…
sharanyashastry Oct 29, 2024
9cfbbb9
Making cost type 3 reflect end effector tracking more accurately.
sharanyashastry Oct 30, 2024
7f49bef
Added changes to visualize the dynamically feasible end effector plan…
sharanyashastry Oct 30, 2024
b4bcc6c
The way we compute cost type 3 now varies with whether force tracking…
sharanyashastry Oct 31, 2024
cfce383
Added verbosity to lcs.cc and c3.cc to print out contact forces for …
sharanyashastry Nov 8, 2024
20d5b15
Changed transparency on visualizer.
sharanyashastry Nov 8, 2024
24ea748
Updated bazel file for log loader.
sharanyashastry Nov 8, 2024
4990235
Define and use new repositioning strategy to avoid hitting jack accid…
ebianchi Nov 19, 2024
253d34c
Avoid getting stuck in repositioning from flipping arc trajectory ove…
ebianchi Nov 19, 2024
61db8e9
Miscellaneous tuning and LCM log loader script, quaternion hessian an…
ebianchi Nov 19, 2024
07168d1
LCM log loader updates
ebianchi Nov 19, 2024
5cf97b0
Fix repositioning bug to prevent drifting away from waypoint1 for arc…
ebianchi Nov 19, 2024
5a7a3b1
Ensure repositioning does not allow trajectory to go below minimum en…
ebianchi Nov 19, 2024
b6a90c4
Add in x_pred reset mechanism if the prediction is too far off
ebianchi Nov 20, 2024
75d374b
Add teleoperation mode that is not locked to a neutral position
ebianchi Nov 20, 2024
7602c6c
Use xbox controller to force into C3 mode
sharanyashastry Nov 21, 2024
26960b2
Some tuning for joint orientation-position goals
sharanyashastry Nov 21, 2024
ec77d20
Remove excess code remnants from LCM log loader, get to working state…
ebianchi Nov 22, 2024
8f2de04
Remove call to old Cassie function that broke compiling in debug mode
ebianchi Nov 25, 2024
3fbd3a3
Update LCM log loader to compute costs evenly sampled around jack at …
ebianchi Nov 25, 2024
f6a9571
Export costs, samples, etc. to files from dense sample evaluation LCM…
ebianchi Nov 26, 2024
3dcdcc2
Python script to generate visuals from densely sampled points generat…
ebianchi Nov 26, 2024
f20ebaf
Get C3 solution by evaluating output port, make port calculation func…
ebianchi Nov 27, 2024
01b5537
Add in progress-based switching between C3 and repositioning
ebianchi Nov 27, 2024
0f29f6e
Hard-code LCM log loader file outputs due to bazel cache location issues
ebianchi Nov 27, 2024
fca6097
Ensure jack URDF matches jack SDF, update cost visualization scripts …
sharanyashastry Nov 27, 2024
e0d7fb2
Update and heed new goal pose when success criteria is met; new poses…
ebianchi Dec 2, 2024
531051e
Merge branch 'sampling_based_c3_dev' of https://github.com/DAIRLab/da…
ebianchi Dec 2, 2024
b431e12
Complete pipeline - position and pose tracking with automatic switchi…
sharanyashastry Dec 3, 2024
e9996c8
Add means of switching out of C3 to depend on position and orientatio…
ebianchi Dec 3, 2024
69d9a8c
Add a combined position and orientation metric for current state to d…
ebianchi Dec 3, 2024
44a4bf9
Clean up old TODO comments
ebianchi Dec 3, 2024
755dcf6
Compute costs with LCS with more contacts with friction values that m…
ebianchi Dec 3, 2024
31c6b8d
Created new sender system for additional costs and publishing all of …
sharanyashastry Dec 3, 2024
1f0cce6
Changes for pose goal randomization.
sharanyashastry Dec 4, 2024
db670a6
Removed additional print statements.
sharanyashastry Dec 4, 2024
8f5ef00
Additional init config for jack related to new test case.
sharanyashastry Dec 4, 2024
6efa573
Maintain and publish a buffer of previously computed samples that are…
ebianchi Dec 6, 2024
c02ba24
More intelligent sample buffer maintenance: get rid of old samples i…
ebianchi Dec 9, 2024
cbc9e26
Ensure random goals within (x, y) limits also obey radius limits
ebianchi Dec 9, 2024
c5fe388
Fix sample buffer indexing bug so LCM messages reflect correct sample…
ebianchi Dec 10, 2024
6879fe5
Make visualizer checkboxes more conveniently located for hiding all p…
ebianchi Dec 11, 2024
b2817c1
Visualize sample buffer contents as point cloud colorized by sample cost
ebianchi Dec 11, 2024
3dbaed1
Enforce repositioning takes route over top of jack when near 180 degr…
ebianchi Dec 12, 2024
d803f3a
Don't include current location in sample buffer
ebianchi Dec 12, 2024
4f8dff0
Publish debugging information over LCM for sampling based C3 controller
ebianchi Dec 16, 2024
18ffc3e
Remove deprecated file from bazel build file
ebianchi Dec 16, 2024
97cba35
Include current position and orientation errors in debug message
ebianchi Dec 16, 2024
cf83adc
Hide typically unchecked visualizations from default vis file to spee…
ebianchi Dec 16, 2024
2ed89df
Avoid numerical issues for sample buffer point cloud e.g. if cloud is…
ebianchi Dec 17, 2024
e08cc50
Use best sample in buffer as potential repositioning target
ebianchi Dec 17, 2024
d479e09
Adjust random goal boundaries to have more safety margin
ebianchi Dec 17, 2024
ce81ce1
Minor tuning; progress made more often if using x_pred for C3 mode
ebianchi Dec 17, 2024
c4165fc
Load C3 vs repositioning mode in LCM log loader
ebianchi Dec 17, 2024
c901fd5
Fix issue in mode switching reason reporting; include debugging script
ebianchi Dec 17, 2024
4807f7b
Properly change all parameters when switching between pose and positi…
ebianchi Dec 17, 2024
799bcd2
Enforce workspace radius limits; make box workspace limits more reaso…
ebianchi Dec 17, 2024
2314701
Make robot platform in simulation more closely match hardware
ebianchi Dec 18, 2024
32dd50e
Include necessary LCM channels in hardware parameters for dynamically…
ebianchi Dec 18, 2024
457a15c
Avoid bazel issues by specifying a bazel version
ebianchi Dec 18, 2024
e16bda6
Configure LCM settings differently for hardware vs simulation automat…
ebianchi Dec 18, 2024
9774bed
Visualize current C3 plans for debugging purposes
ebianchi Dec 19, 2024
eb85e14
Use tighter spherical surface samples and repositioning radius
ebianchi Dec 19, 2024
e9b673c
Make sim platform more closely match hardware setup
ebianchi Dec 19, 2024
84e599c
Implement orientation cycling goal updates after reaching success thr…
ebianchi Dec 19, 2024
1214541
Correct inaccurate documentation on 8 stable orientation visualizatio…
ebianchi Dec 19, 2024
6d37394
Tweaks for better hardware experiments: re-enable xbox so teleop mode…
ebianchi Dec 19, 2024
a027e12
Devise new camera calibration procedure using robot table and Aruco t…
ebianchi Dec 20, 2024
3fdc2cc
Ignore camera calibration python virtual environment
ebianchi Dec 20, 2024
a21e70e
Minimize LCM traffic interference
ebianchi Jan 6, 2025
223635a
Add ability to resolve different number of contacts for current locat…
ebianchi Jan 6, 2025
79b8bd3
Draft visualization of time to reach goal given different success thr…
ebianchi Jan 7, 2025
28640ea
Updated hardware weights.
sharanyashastry Jan 9, 2025
0385fb4
Remove printout from OSC
sharanyashastry Jan 9, 2025
9bda970
Various experiment-driven updates: count goals and eliminate infinit…
ebianchi Jan 14, 2025
1218489
Merge branch 'sampling_based_c3_dev' of https://github.com/DAIRLab/da…
ebianchi Jan 14, 2025
c2cda22
Ignore camera calibrations
ebianchi Jan 14, 2025
80895bd
Finish updating sampling C3 controller debug message; output info fro…
ebianchi Jan 14, 2025
1d9dd38
added stopping commands to hardware procman init script/
sharanyashastry Jan 11, 2025
6e90436
Add ability to prevent 3-topples-required random pose goals
ebianchi Jan 15, 2025
5668da3
Check sample validity based on robot radius limits in addition to XY …
ebianchi Jan 15, 2025
a9d0506
Initialize buffer-related plans properly
ebianchi Jan 15, 2025
8011a93
Plot updates: mode switching, goal completion draft, etc.
ebianchi Jan 16, 2025
dc3a62f
Box topple example setup. Tuning in progress.
sharanyashastry Jan 16, 2025
43021ba
Fix bug to properly ensure random pose goals are at least 90 degrees …
ebianchi Jan 16, 2025
a060ef1
Merge branch 'sampling_based_c3_dev' of https://github.com/DAIRLab/da…
ebianchi Jan 16, 2025
477306e
Plot updates: time to goal histograms, time to goal versus errors
ebianchi Jan 17, 2025
b1ea646
add video writer - still need to do bindings and test
Brian-Acosta Jan 23, 2025
470bd30
Modified box sdf and added ground_modified sdf to have hydroelastic t…
sharanyashastry Jan 24, 2025
5b40230
Modified box.sdf to have spheres with explicit 0 masses.
sharanyashastry Jan 24, 2025
40bf0b2
Added log loader for box topple example.
sharanyashastry Jan 24, 2025
e3e812b
need to re-add if statements controlling what's visualized, add a sta…
Brian-Acosta Jan 24, 2025
99ad7c0
WIP progress on plot generation, still to be cleaned up
ebianchi Jan 24, 2025
28fa256
Merge branch 'sampling_based_c3_dev' of https://github.com/DAIRLab/da…
ebianchi Jan 24, 2025
ee162d0
mvp should work, need to test
Brian-Acosta Jan 24, 2025
af2bcae
Merge remote-tracking branch 'origin/sampling_based_c3_dev_add_visual…
sharanyashastry Jan 24, 2025
297d168
add video writer from brian's branch
sharanyashastry Jan 24, 2025
e7759e0
Plot formatting updates for easier viewing
ebianchi Jan 25, 2025
e38154c
Merge branch 'sampling_based_c3_dev' of https://github.com/DAIRLab/da…
ebianchi Jan 25, 2025
d168ca7
Draft enforcing angle lookahead consistency when rotation errors near…
ebianchi Jan 27, 2025
9fc872c
Test and verify angle hysteresis to handle 180 degree error case
ebianchi Jan 27, 2025
e470d84
Adding cost related analysis to lcm_log_loader and verbose mode of c3.cc
sharanyashastry Jan 28, 2025
6b9aa9f
Added new 3 topple test case used for analysis from hw log.
sharanyashastry Jan 28, 2025
8c952cf
updated hardware params aimed at more efficiency.
sharanyashastry Jan 28, 2025
829fcf7
Generate videos to visualize progress to goal
ebianchi Jan 29, 2025
3778462
Merge branch 'sampling_based_c3_dev' of https://github.com/DAIRLab/da…
ebianchi Jan 29, 2025
ee4cab8
Minor tweaks to prepare for generating goal progress videos; begin dr…
ebianchi Jan 30, 2025
c0baadc
Generate video overlays
ebianchi Feb 1, 2025
241efd4
Plot formatting
ebianchi Feb 1, 2025
e0d5069
Working push-T example. May want to make the T smaller to avoid WSL.
sharanyashastry Feb 11, 2025
1536659
Smaller T
sharanyashastry Feb 12, 2025
7f4fea4
Params for smaller T.
sharanyashastry Feb 12, 2025
742c529
- Bigger T.
sharanyashastry Feb 18, 2025
24eb689
Push-T procman and logging scripts.
sharanyashastry Feb 18, 2025
e16af80
Making box example compatible with new repositioning definition.
sharanyashastry Feb 25, 2025
987ed55
Reverting the more aggressive params.
sharanyashastry Feb 25, 2025
847f439
Updating the num_loops_to_wait, as in final hardware experiments. Als…
sharanyashastry Feb 25, 2025
84eb93a
Cost visualization script for push_T example.
sharanyashastry Feb 25, 2025
0064933
T changed to 16x4x4cm. Smaller end effector and corresponding visuali…
sharanyashastry Feb 25, 2025
49516db
Added new cost types 4(same as 3 with ee plan replaced with C3 plan) …
sharanyashastry Feb 27, 2025
5480982
Fixing bug in cost computation due to the remnant two lines from the …
sharanyashastry Feb 28, 2025
22fc067
Added new verbose print for controller.
sharanyashastry Mar 4, 2025
f2b66db
Ensure installing prereqs includes and uses bazel
ebianchi Mar 6, 2025
3a5e43f
Added new sampling strategy that randomly samples on a grid and proje…
sharanyashastry Mar 7, 2025
66ecbc2
New repositioning trajectory to be compatible with new sampling. Ensu…
sharanyashastry Mar 11, 2025
0664736
New progress measurement method - when in c3, if cost has not reduced…
sharanyashastry Mar 13, 2025
3eb7ce2
Updated push_T params with new progress metric.
sharanyashastry Mar 13, 2025
452b504
Reverting change in ee constraint and adding cost breakdown print on …
sharanyashastry Mar 18, 2025
424eaf8
Printout cost breakdown on pressing xbox.
sharanyashastry Mar 19, 2025
21d8002
Added sampling in a shell and projecting to surface.
sharanyashastry Mar 19, 2025
0390ef9
Updated end-effector to match the hardware. Added tuned params from l…
sharanyashastry Mar 19, 2025
be0e061
Normalizing quaternion to avoid error in jacktoy cost_visualization s…
sharanyashastry Mar 19, 2025
23738a0
Tweaks made for T-Hardware experiments.
sharanyashastry Mar 21, 2025
10f11ef
Fixing hardware procman for T.
sharanyashastry Mar 21, 2025
ebf3de8
Hardware T params.
sharanyashastry Mar 21, 2025
9678476
Bug fix in plotting script when merging results from multiple logs.
sharanyashastry Mar 21, 2025
f87138c
Avoid repositioning stuck bugs due to nans from poorly behaved arccos
ebianchi Mar 26, 2025
a2bca88
Equality constraint modified during T experiments. Added warning comm…
sharanyashastry Mar 27, 2025
05a58f3
Use xbox to print current pos_rot_cost to help with progress metric t…
sharanyashastry Mar 27, 2025
86bdfa8
Modified the t_line condition to avoid floating point errors.
sharanyashastry Mar 27, 2025
0b09660
Modifying sim jack model to match real.
sharanyashastry Mar 28, 2025
e9043d3
Jacktoy parameters updated to ensure compatibility with new params in…
sharanyashastry Mar 28, 2025
702ebd9
Deprecating ros_lcm_bridge files.
sharanyashastry Mar 28, 2025
d3cff5f
Removed unused urdfs in each example. Updated parameter files for box…
sharanyashastry Mar 31, 2025
c381e5c
Deprecated safe params.
sharanyashastry Mar 31, 2025
b866a95
Removed some unused prints.
sharanyashastry Mar 31, 2025
e7d6b33
Moved all shared systems to dairlib systems folder under sender_syste…
sharanyashastry Apr 1, 2025
f9bb82a
Bringing ball rolling example mostly up to date to get it to build.
sharanyashastry Apr 4, 2025
c2a97bf
Moving all examples to examples/sampling_c3 and having them share urd…
sharanyashastry Apr 4, 2025
25f31e6
Consolidate logging scripts. Move procmans to each example.
sharanyashastry Apr 5, 2025
99ab7e8
Reverting changes in trifinger folder.
sharanyashastry Apr 5, 2025
b2c252a
Reverting all old borrowed plotting scripts since we now use our own.
sharanyashastry Apr 7, 2025
f73b06d
Reverting cassie networking file chanegs.
sharanyashastry Apr 7, 2025
88c1603
Reverting change in franka/systems
sharanyashastry Apr 7, 2025
4e15733
Merge remote-tracking branch 'origin/sampling_based_c3_public' into s…
sharanyashastry Apr 7, 2025
95e623c
Deleted white spaces in plotting files.
sharanyashastry Apr 8, 2025
54b43e5
Updating reference to franka model in bazel file so it builds..
sharanyashastry Apr 8, 2025
bd910d3
Deleted unused meshcat video making files.
sharanyashastry Apr 8, 2025
1d7c487
Revert new line change in PR.
sharanyashastry Apr 8, 2025
101ec30
Reverting some random changes in old plotting files. Also removing un…
sharanyashastry Apr 9, 2025
1c8a788
Reverting breaking changes from drake version mismatch between branches.
sharanyashastry Apr 9, 2025
22158de
Using cleaned up version of computecontactjacobian function from lcsf…
sharanyashastry Apr 9, 2025
b40d4c1
Reverting some changes in c3.cc that came from the merge. Ensuring vi…
sharanyashastry Apr 9, 2025
89e4858
Minimal visualization system changes.
sharanyashastry Apr 9, 2025
6cccdd1
Removed dependency to lcs_factory_system. Matched object sender defin…
sharanyashastry Apr 9, 2025
1e7f264
Reverting franka_model description in unrelated files to match plate_…
sharanyashastry Apr 10, 2025
29f8551
Matching franka_description model description in unrelated file to pl…
sharanyashastry Apr 10, 2025
2162ebd
Removing unused imports related to meshcat video capture files.
sharanyashastry Apr 10, 2025
9fdadf7
Consolidating osc, sim and visualizer files accross examples to be ab…
sharanyashastry Apr 23, 2025
ccb1435
Deleting a few more urdfs.
sharanyashastry Apr 23, 2025
84c7de0
Removed more urdfs that were unused and replaced repeated urdfs from …
sharanyashastry Apr 25, 2025
fb5a74d
Deleting readmes.
sharanyashastry Apr 25, 2025
d49417a
Removing some new line changes.
sharanyashastry Apr 25, 2025
15eae74
More whitespace changes.
sharanyashastry Apr 25, 2025
06dced6
Removed unused saved_trajectories folder.
sharanyashastry Apr 25, 2025
a4b7b2c
Consolidating all shared params and franka_bridge_drivers.
sharanyashastry Apr 28, 2025
5b3dd2f
Consolidated trajectory_params.h
sharanyashastry Apr 28, 2025
a16d4fd
Removing some unused test files.
sharanyashastry Apr 28, 2025
f92ffe7
Remove test scripts and URDFs only used by them
ebianchi May 5, 2025
61f8cc8
Remove camera calibration script
ebianchi May 5, 2025
67bdb15
Added a SISO generic sender to usurp the c3_mode sender, sample locat…
sharanyashastry May 6, 2025
4363525
Consolidated franka_c3_controller files.
sharanyashastry May 7, 2025
c6df5eb
Corresponding changes to hardware procmans from consolidating franka_…
sharanyashastry May 7, 2025
2e47405
Consolidated log_loaders to shared test folder.
sharanyashastry May 7, 2025
f94df78
Consolidated cost_visualization script.
sharanyashastry May 7, 2025
4374ba9
Added functionality to modify color and size of visualization models …
sharanyashastry May 8, 2025
e1840ae
Got rid of c3_trajectory generator and tracking_trajectory_generator …
sharanyashastry May 8, 2025
221cd1a
Deleted jack.urdf since we use jack.sdf
sharanyashastry May 8, 2025
97c14a0
Reverted a change from franka example.
sharanyashastry May 8, 2025
8d156f9
Removed some more changes that were made to systems/c3 that are no lo…
sharanyashastry May 8, 2025
dda4e75
Made everything that didn't need to got through a sender, directly ou…
sharanyashastry May 13, 2025
d4550eb
Moved c3_mode_visualizer out of sender systems and into the sampling-…
sharanyashastry May 14, 2025
f12c2b7
Moved osc related systems out of sender systems and into dairlib/syst…
sharanyashastry May 14, 2025
b992405
Built a shared control_target_generator that now lives under sampling…
sharanyashastry May 15, 2025
98a130e
Deleted LCSFactoryPreprocessor and made it a function inside LCSFactory.
sharanyashastry May 15, 2025
36f0165
Changes related to new drake version.
sharanyashastry May 15, 2025
577431a
Isolated sampling_c3_options related to resolving contacts etc. into …
sharanyashastry May 16, 2025
e888220
Removed some stuff out of the gitignore and moved the virutal environ…
sharanyashastry May 16, 2025
97edf16
Deleted all old svg files and moved target directory for new diagrams…
sharanyashastry May 16, 2025
5a718db
Updating bazeliskrc files to use bazel version 7.1.1
sharanyashastry May 16, 2025
d5656d1
Isolating xbox changes to new script under sampling_c3.
sharanyashastry May 16, 2025
8909742
Removing bazelisk related MODULE files from gitignore. These show up …
sharanyashastry May 16, 2025
ab0837a
Removing new line change from gitignore.
sharanyashastry May 16, 2025
f660fef
new line change.
sharanyashastry May 16, 2025
a60b66c
Matching the c3 Solve API to that of Will's branch.
sharanyashastry May 16, 2025
2854aaf
Keeping drake at the last version that uses drake/manipulation/models…
sharanyashastry May 16, 2025
ac3ae46
Added sampling_c3_options to logging script.
sharanyashastry May 16, 2025
a8aed4a
Making sure franka-joint_osc reads the paths correctly based on demo …
sharanyashastry May 16, 2025
09f7519
Changes to get the full branch to build with the newest version of dr…
sharanyashastry May 16, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 2 additions & 31 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -54,26 +54,8 @@ These dependencies are necessary for some advanced visualization and process man
#### LCM and libbot
Install a local copy of `lcm` and `libbot2` using `sudo apt install lcm libbot2`. The prerequisites installation (option 1.a) should add the proper apt repo for these.

#### ROS
To integrate with ROS (tested on ROS Noetic with 20.04), the following steps are required.
1. Install ROS http://wiki.ros.org/ROS/Installation
2. Do not forget to setup your environment. For instance, add these lines to `~/.bashrc`
```
export ROS_MASTER_URI=http://localhost:11311
source /opt/ros/noetic/setup.bash
```
3. Install additional dependencies
```
sudo apt install python3-rosinstall-generator python-catkin-tools python3-vcstool
```
4. Build the ROS workspace using catkin. From `dairlib/`,
```
sudo ./tools/workspace/ros/compile_ros_workspace.sh
```
5. Set the environment variable `DAIRLIB_WITH_ROS` to `ON`. For instance, add to `~/.bashrc`
```
export DAIRLIB_WITH_ROS=ON
```
#### Install procman
Install procman from https://github.com/ashuang/procman

#### Invariant-EKF
State Estimation for Cassie is done using contact-aided invariant-EKF. `invariant-ekf` is an external repository forked from Ross Hartley's repository of the same name. By default, a pegged version of this forked repository is used i.e. the `bazel` branch of DAIR lab's fork of `invariant-ekf` is automatically downloaded and used. However, to make changes to the files, the [DAIR Lab's fork of invariant-ekf](https://github.com/DAIRLab/invariant-ekf/tree/bazel "DAIR Lab's fork of invariant-ekf") can be cloned as a local repository.
Expand All @@ -96,14 +78,3 @@ Build what you want via Bazel. From `dairlib`, `bazel build ...` will build the
## Included Modules
A list of included modules

### DIRCON
A modern Drake implementation of the DIRCON constrained trajectory optimization algorithm. Currently under construction. See `/examples/PlanarWalker/run_gait_dircon.cc` for a simple example of the hybrid DIRCON algorithm. The more complete example set (from the paper) currently exists on an older version of Drake https://github.com/mposa/drake/tree/hybrid-merge

Based off the publication

Michael Posa, Scott Kuindersma, Russ Tedrake. "Optimization and Stabilization of Trajectories for Constrained Dynamical Systems." Proceedings of the International Conference on Robotics and Automation (ICRA), 2016.

Available online at https://posa.seas.upenn.edu/wp-content/uploads/Posa16a.pdf

## Docker (experimental)
Docker support is currently experimental. See `install/bionic/Dockerfile` for an Ubuntu Dockerfile. Docker is being used in conjuction with Cirrus Continuous Integration, and should be better supported in the future.
4 changes: 2 additions & 2 deletions WORKSPACE
Original file line number Diff line number Diff line change
Expand Up @@ -11,9 +11,9 @@ workspace(name = "dairlib")
# export DAIRLIB_LOCAL_DRAKE_PATH=/home/user/workspace/drake

# Choose a revision of Drake to use.
DRAKE_COMMIT = "v1.22.0"
DRAKE_COMMIT = "v1.33.0"

DRAKE_CHECKSUM = "78cf62c177c41f8415ade172c1e6eb270db619f07c4b043d5148e1f35be8da09"
DRAKE_CHECKSUM = "2713ad1ea53ed7b9cfe1ba751eeeab7dc173408753ead21b7bafb0436b92dcf3"
# Before changing the COMMIT, temporarily uncomment the next line so that Bazel
# displays the suggested new value for the CHECKSUM.
#DRAKE_CHECKSUM = "0" * 64
Expand Down
4 changes: 2 additions & 2 deletions bindings/pydairlib/solvers/c3_py.cc
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,11 @@ PYBIND11_MODULE(c3, m) {
.def(py::init<const LCS&, const dairlib::solvers::C3::CostMatrices&,
const vector<VectorXd>&, const C3Options&>(),
arg("LCS"), arg("costs"), arg("x_des"), arg("c3_options"))
.def("Solve", &C3MIQP::Solve, arg("x0"))
.def("Solve", &C3MIQP::Solve, arg("x0"), arg("verbose") = false)
.def("UpdateTarget", &C3MIQP::UpdateTarget, arg("x0"))
.def("UpdateLCS", &C3MIQP::UpdateLCS, arg("lcs"))
.def("ADMMStep", &C3MIQP::ADMMStep, arg("x0"), arg("delta"), arg("w"),
arg("G"), arg("admm_iteration"))
arg("G"), arg("admm_iteration"), arg("verbose") = false)
.def("SolveQP", &C3MIQP::SolveQP, arg("x0"), arg("G"), arg("WD"),
arg("admm_iteration"), arg("is_final_solve"))
.def("SolveProjection", &C3MIQP::SolveProjection, arg("U"), arg("WZ"), arg("admm_iteration"))
Expand Down
271 changes: 271 additions & 0 deletions examples/sampling_c3/BUILD.bazel
Original file line number Diff line number Diff line change
@@ -0,0 +1,271 @@
package(default_visibility = ["//visibility:public"])

cc_library(
name = "urdfs",
data = glob([
"urdf/**",
]),
)

filegroup(
name = "all_example_params_yamls",
srcs = glob(["*/parameters/*.yaml"]),
visibility = ["//visibility:public"],
)

filegroup(
name = "shared_params_yamls",
srcs = glob(["shared_parameters/*.yaml"]),
visibility = ["//visibility:public"],
)

cc_binary(
name = "franka_sim",
srcs = ["franka_sim.cc"],
data = [
":urdfs",
"//examples/sampling_c3:all_example_params_yamls",
"@drake_models//:franka_description",
],
deps = [
"//examples/sampling_c3/parameter_headers:franka_lcm_channels",
"//examples/sampling_c3/parameter_headers:franka_sim_params",
"//common",
"//systems:robot_lcm_systems",
"//systems:system_utils",
"//systems/framework:lcm_driven_loop",
"@drake//:drake_shared_library",
"@gflags",
],
)

cc_binary(
name = "franka_osc_controller",
srcs = ["franka_osc_controller.cc"],
data = [
":urdfs",
"//examples/sampling_c3:all_example_params_yamls",
"@drake_models//:franka_description",
],
deps = [
"//examples/sampling_c3/parameter_headers:franka_lcm_channels",
"//examples/sampling_c3/parameter_headers:franka_osc_controller_params",
"//common",
"//systems:franka_systems",
"//lcm:lcm_trajectory_saver",
"//systems:robot_lcm_systems",
"//systems:system_utils",
"//systems/controllers:gravity_compensator",
"//systems/controllers/osc:operational_space_control",
"//systems/framework:lcm_driven_loop",
"//systems/trajectory_optimization:lcm_trajectory_systems",
"@drake//:drake_shared_library",
"@gflags",
],
)

cc_binary(
name = "franka_joint_osc_controller",
srcs = ["franka_joint_osc_controller.cc"],
data = [
":urdfs",
"//examples/sampling_c3:all_example_params_yamls",
"@drake_models//:franka_description",
],
deps = [
"//examples/sampling_c3/parameter_headers:franka_lcm_channels",
"//examples/sampling_c3/parameter_headers:franka_osc_controller_params",
"//common",
"//systems:franka_systems",
":joint_trajectory_generator",
"//lcm:lcm_trajectory_saver",
"//systems:robot_lcm_systems",
"//systems:system_utils",
"//systems/controllers:gravity_compensator",
"//systems/controllers/osc:operational_space_control",
"//systems/framework:lcm_driven_loop",
"//systems/primitives:radio_parser",
"//systems/trajectory_optimization:lcm_trajectory_systems",
"@drake//:drake_shared_library",
"@gflags",
],
)



cc_library(
name = "joint_trajectory_generator",
srcs = ["joint_trajectory_generator.cc"],
hdrs = ["joint_trajectory_generator.h"],
deps = [
"//systems/framework:vector",
],
)
cc_binary(
name = "franka_visualizer",
srcs = ["franka_visualizer.cc"],
data = [
":urdfs",
"//examples/sampling_c3:all_example_params_yamls",
"@drake_models//:franka_description",
],
deps = [
":c3_mode_visualizer",
"//solvers:c3",
"//examples/sampling_c3/parameter_headers:franka_lcm_channels",
"//examples/sampling_c3/parameter_headers:franka_sim_params",
"//examples/sampling_c3/parameter_headers:franka_c3_controller_params",
"//systems/controllers:sampling_params",
"//common",
"//multibody:utils",
"//multibody:visualization_utils",
"//systems/sender_systems:sender_systems",
"//systems:franka_systems",
"//systems:robot_lcm_systems",
"//systems:system_utils",
"//systems/primitives",
"//systems/trajectory_optimization:lcm_trajectory_systems",
"//systems/visualization:lcm_visualization_systems",
"@drake//:drake_shared_library",
"@gflags",
],
)

cc_binary(
name = "franka_bridge_driver_out",
srcs = ["franka_bridge_driver_out.cc"],
data = [
":urdfs",
"@drake_models//:franka_description",
"//examples/sampling_c3:all_example_params_yamls",
"//examples/sampling_c3:shared_params_yamls",
],
deps = [
"//examples/sampling_c3/parameter_headers:franka_lcm_channels",
"//examples/sampling_c3/parameter_headers:franka_drake_lcm_driver_channels",
"//examples/sampling_c3/parameter_headers:franka_sim_params",
"//common",
":franka_state_translator",
"//multibody:utils",
"//systems:robot_lcm_systems",
"//systems:system_utils",
"//systems/framework:lcm_driven_loop",
"//systems/primitives",
"@drake//:drake_shared_library",
"@gflags",
],
)

cc_binary(
name = "franka_bridge_driver_in",
srcs = ["franka_bridge_driver_in.cc"],
data = [
":urdfs",
"@drake_models//:franka_description",
"//examples/sampling_c3:all_example_params_yamls",
"//examples/sampling_c3:shared_params_yamls",
],
deps = [
"//examples/sampling_c3/parameter_headers:franka_lcm_channels",
"//examples/sampling_c3/parameter_headers:franka_drake_lcm_driver_channels",
"//examples/sampling_c3/parameter_headers:franka_sim_params",
"//common",
":franka_state_translator",
"//multibody:utils",
"//systems:robot_lcm_systems",
"//systems:system_utils",
"//systems/framework:lcm_driven_loop",
"//systems/primitives",
"@drake//:drake_shared_library",
"@gflags",
],
)

cc_binary(
name = "franka_c3_controller",
srcs = ["franka_c3_controller.cc"],
data = [
":urdfs",
"@drake_models//:franka_description",
"//examples/sampling_c3:all_example_params_yamls",
"//examples/sampling_c3:shared_params_yamls",
],
deps = [
"//examples/sampling_c3/parameter_headers:franka_lcm_channels",
"//examples/sampling_c3/parameter_headers:franka_sim_params",
"//examples/sampling_c3/parameter_headers:trajectory_params",
"//systems/controllers:sampling_params",
"//common",
"//systems:franka_systems",
"//systems/sender_systems:sample_buffer_sender",
"//systems/sender_systems:sender_systems",
":control_target_generator",
"//lcm:lcm_trajectory_saver",
"//systems:robot_lcm_systems",
"//systems:system_utils",
"//systems/controllers:sampling_c3_controller",
"//systems/framework:lcm_driven_loop",
"//systems/trajectory_optimization:c3_output_systems",
"@drake//:drake_shared_library",
"@gflags",
],
)


cc_library(
name = "c3_mode_visualizer",
srcs = ["c3_mode_visualizer.cc"],
hdrs = ["c3_mode_visualizer.h"],
deps = [
"//lcmtypes:lcmt_robot",
"//lcm:lcm_trajectory_saver",
"//systems/framework:vector",
"@drake//:drake_shared_library",
"@lcm",
],
)

cc_library(
name = "franka_state_translator",
srcs = [
"franka_state_translator.cc",
],
hdrs = [
"franka_state_translator.h",
],
deps = [
"//lcmtypes:lcmt_robot",
"//systems/framework:vector",
"@drake//:drake_shared_library",
],
)


cc_library(
name = "control_target_generator",
srcs = ["control_target_generator.cc"],
hdrs = ["control_target_generator.h"],
deps = [
"//lcmtypes:lcmt_robot",
"//multibody:utils",
"//systems/framework:vector",
"@drake//:drake_shared_library",
"//solvers:c3",
"//examples/sampling_c3/parameter_headers:franka_c3_controller_params",
"//systems/controllers:sampling_params",
"//lcm:lcm_trajectory_saver",
"@lcm",
],
)

py_binary(
name = "xbox_script",
srcs = ["xbox_script.py"],
data = [
"@lcm//:lcm-python",
],
main = "xbox_script.py",
deps = [
"//lcmtypes:lcmtypes_robot_py",
],
)
Loading