{"id":18385913,"url":"https://github.com/uzh-rpg/high_mpc","last_synced_at":"2025-04-05T15:06:34.756Z","repository":{"id":40440094,"uuid":"246802772","full_name":"uzh-rpg/high_mpc","owner":"uzh-rpg","description":"Policy Search for Model Predictive Control with Application to Agile Drone Flight","archived":false,"fork":false,"pushed_at":"2022-03-28T21:40:25.000Z","size":111174,"stargazers_count":470,"open_issues_count":3,"forks_count":102,"subscribers_count":23,"default_branch":"master","last_synced_at":"2025-03-29T14:09:10.517Z","etag":null,"topics":["mpc","policysearch","quadrotor"],"latest_commit_sha":null,"homepage":"","language":"C","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/uzh-rpg.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2020-03-12T10:10:51.000Z","updated_at":"2025-03-24T07:21:39.000Z","dependencies_parsed_at":"2022-09-17T20:50:38.933Z","dependency_job_id":null,"html_url":"https://github.com/uzh-rpg/high_mpc","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uzh-rpg%2Fhigh_mpc","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uzh-rpg%2Fhigh_mpc/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uzh-rpg%2Fhigh_mpc/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/uzh-rpg%2Fhigh_mpc/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/uzh-rpg","download_url":"https://codeload.github.com/uzh-rpg/high_mpc/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247353731,"owners_count":20925329,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["mpc","policysearch","quadrotor"],"created_at":"2024-11-06T01:19:32.840Z","updated_at":"2025-04-05T15:06:30.329Z","avatar_url":"https://github.com/uzh-rpg.png","language":"C","funding_links":[],"categories":[],"sub_categories":[],"readme":"## Policy Search for Model Predictive Control with Application to Agile Drone Flight\n\n\u003c!-- [![Method](docs/figures/method.png)](https://youtu.be/Qei7oGiEIxY) --\u003e\n\n![High_MPC_Demo](docs/gifs/prompc.gif)\n\nPolicy Search and Model Predictive Control (MPC) are two different paradigms for robot control: policy search has the strength of automatically learning complex policies using experienced data, while MPC can offer optimal control performance using models and trajectory optimization. An open research question is how to leverage and combine the advantages of both approaches. In this work, we provide an answer by using policy search for automatically choosing high-level decision variables for MPC, which leads to a novel policy-search-for-model-predictive-control framework. Specifically, we formulate the MPC as a parameterized controller, where the hard-to-optimize decision variables are represented as high-level policies. Such a formulation allows optimizing policies in a self-supervised fashion. We validate this framework by focusing on a challenging problem in agile drone flight: flying a quadrotor through fast-moving gates. Experiments show that our controller achieves robust and real-time control performance in both simulation and the real world. The proposed framework offers a new perspective for merging learning and control.\n\n### Publication\n\nIf you use this code in a publication, please cite the following papers:\n\nY. Song and D. Scaramuzza,\n\"**Policy Search for Model Predictive Control with Application to Agile Drone Flight**,\"\nIEEE Transaction on Robotics (T-RO), 2021.\n[[PDF](http://rpg.ifi.uzh.ch/docs/TRO21_Yunlong.pdf)][[Video](https://youtu.be/Qei7oGiEIxY)]\n\nY. Song and D. Scaramuzza,\n\"**Learning High-Level Policies for Model Predictive Control**,\"\nIEEE/RSJ International Conference on Intelligent Robots and Systems (IROS), Las Vegas, 2020.\n[[PDF](http://rpg.ifi.uzh.ch/docs/IROS20_Yunlong.pdf)][[Video](https://youtu.be/2uQcRnp7yI0)]\n\n```\n@article{song2022policy,  \n  author={Song, Yunlong and Scaramuzza, Davide},  \n  journal={IEEE Transactions on Robotics},   \n  title={Policy Search for Model Predictive Control With Application to Agile Drone Flight},   \n  year={2022}, \n  pages={1-17},  \n  doi={10.1109/TRO.2022.3141602}\n}\n```\n```\n@inProceedings{song2020learning,\n  title={Learning High-Level Policies for Model Predictive Control},\n  author={Song, Yunlong and Scaramuzza, Davide},\n  booktitle={IEEE/RSJ International Conference on Intelligent Robots and Systems (IROS)},\n  year={2020}\n}\n```\n### Demonstrations\n\nPlease find a list of demonstrations in [here](docs/gifs/README.md) and in the video below:\n\n[![Method](docs/figures/image.png)](https://youtu.be/Qei7oGiEIxY)\n\n\n### Installation\n\nClone the repo\n\n```\ngit clone git@github.com:uzh-rpg/high_mpc.git\n```\n\nInstallation Dependencies:\n\n```\ncd high_mpc\npip install -r requirements.txt\n```\n\nAdd the repo path to your PYTHONPATH by adding the following to your ~/.bashrc\n\n```\nexport PYTHONPATH=${PYTHONPATH}:/path/to/high_mpc\n```\n\n### Run\n\nStandard MPC\n\n```\ncd high_mpc\npython3 run_mpc.py\n```\n\nLearning a High-Level Policy\n\n```\npython3 run_highmpc.py\n```\n\nLearning a Deep High-Level Policy\n\n```\n# collect training data for the MLP\npython3 run_deep_highmpc.py --option 0\n\n# train the deep high-level policy with pre-collected data\npython3 run_deep_highmpc.py --option 1\n\n# evaluate the performance with pre-trained deep high-level policy\npython3 run_deep_highmpc.py --option 2\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuzh-rpg%2Fhigh_mpc","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fuzh-rpg%2Fhigh_mpc","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fuzh-rpg%2Fhigh_mpc/lists"}