{"id":22954456,"url":"https://github.com/offdroid/lfd-robotics-science-sys-intelligence","last_synced_at":"2025-04-02T00:23:21.401Z","repository":{"id":215960169,"uuid":"740091884","full_name":"offdroid/lfd-robotics-science-sys-intelligence","owner":"offdroid","description":null,"archived":false,"fork":false,"pushed_at":"2024-01-07T16:24:50.000Z","size":6683,"stargazers_count":1,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-07T15:45:06.281Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"language":"Python","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/offdroid.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,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-01-07T14:00:14.000Z","updated_at":"2024-05-14T03:23:45.000Z","dependencies_parsed_at":null,"dependency_job_id":"3659b39b-7c8e-4758-99d6-e5863cc03dd4","html_url":"https://github.com/offdroid/lfd-robotics-science-sys-intelligence","commit_stats":null,"previous_names":["offdroid/lfd-robotics-science-sys-intelligence"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/offdroid%2Flfd-robotics-science-sys-intelligence","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/offdroid%2Flfd-robotics-science-sys-intelligence/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/offdroid%2Flfd-robotics-science-sys-intelligence/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/offdroid%2Flfd-robotics-science-sys-intelligence/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/offdroid","download_url":"https://codeload.github.com/offdroid/lfd-robotics-science-sys-intelligence/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246731446,"owners_count":20824554,"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":[],"created_at":"2024-12-14T16:17:12.480Z","updated_at":"2025-04-02T00:23:21.393Z","avatar_url":"https://github.com/offdroid.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# LfD\n\nThe `opirl` folder contains the code from `https://github.com/sff1019/opirl` and `rl-baselines3-zoo` is from `https://github.com/DLR-RM/rl-baselines3-zoo`.\n`opirl/mujoco210-linux-x86_64.tar.gz` is from `https://mujoco.org/download/mujoco210-linux-x86_64.tar.gz`.\n\nMake sure to have followed the installation instructions found in both repositories!\nShould you encounter issues use Docker or verify that the installation, as done in the Dockerfile, works on your system.\n\nThe expert trajectories are already generated and found in `opirl/experts/sac/swimmer/expert/`.\nTo generate them yourself, first download the the model\n```\n# from the `rl-baselines3-zoo` folder\npython -m rl_zoo3.load_from_hub --algo sac --env Swimmer-v3 -orga sb3 -f logs/\n```\nThen run\n```\npython generate_expert_trajectories.py\n```\nfrom the same directory.\nThis will create 16 trajectories in `opirl/experts/sac/swimmer/expert/`.\n\nFor Docker run the following commands inside the `opirl` folder\n```\ndocker build -t opirl .\ndocker run -v \"/path/to/results/on/local/machine:/app/results\" -it --rm opirl --algo opirl --normalize_states --use_bc_reg --learn_alpha --seed 1 --max_timesteps 1000000 --env_name Swimmer-v2 --expert_path_dir /app/experts/sac/swimmer/expert --save_dir results/opirl/swimmer\n```\nBe sure to update the `/path/to/results/on/local/machine` to where ever you want the results to be written to (absolute path!).\nRun with different seeds to test robustness.\n\n\nWithout docker use\n```\npython -u run_opirl.py --algo opirl --normalize_states --use_bc_reg --learn_alpha --seed 1 --max_timesteps 1000000 --env_name Swimmer-v2 --expert_path_dir experts/sac/swimmer/expert --save_dir results/opirl/swimmer\n```\nfrom the `opirl` directory.\nAlternatively, use the script in `opirl/scripts`.\n\nThe results are found in the results directory.\nMost interesting is the `eval.csv` file which contains the policy evaluations during regular intervals of the training.\n\nPlot the results using `plot.py`. Update the path to the results first, if necessary.\nRequires `pip install seaborn pandas`.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foffdroid%2Flfd-robotics-science-sys-intelligence","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Foffdroid%2Flfd-robotics-science-sys-intelligence","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Foffdroid%2Flfd-robotics-science-sys-intelligence/lists"}