{"about":{"site":"https://codewithpapers.app","non_affiliation":"Code with Papers and Syntology are not affiliated with, endorsed by, or sponsored by Papers with Code, Meta, or the pwc-archive mirror.","licence":"CC BY-SA 4.0","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","attribution":"https://codewithpapers.app/attribution","modified":"archive material modified by Syntology; see the attribution page"},"url":"/paper/imitation-learning-by-reinforcement-learning","title":"Imitation Learning by Reinforcement Learning","arxiv_id":"2108.04763","date":"2021-08-10","proceeding":"ICLR 2022 4","authors":["Kamil Ciosek"],"abstract":"Imitation learning algorithms learn a policy from demonstrations of expert behavior. We show that, for deterministic experts, imitation learning can be done by reduction to reinforcement learning with a stationary reward. Our theoretical analysis both certifies the recovery of expert reward and bounds the total variation distance between the expert and the imitation learner, showing a link to adversarial imitation learning. We conduct experiments which confirm that our reduction works well in practice for continuous control tasks.","url_abs":"https://arxiv.org/abs/2108.04763v2","url_pdf":"https://arxiv.org/pdf/2108.04763v2.pdf","source":{"archive":"pwc-archive (Hugging Face), CC BY-SA 4.0","snapshot":"2025-07-28","licence_url":"https://creativecommons.org/licenses/by-sa/4.0/legalcode","row_kind":"abstracts"},"code_links":[{"paper_slug":"imitation-learning-by-reinforcement-learning","repo_url":"https://github.com/spotify-research/il-by-rl","is_official":1,"mentioned_in_paper":0,"mentioned_in_github":0,"framework":"pytorch","reach":{"status":"ok","spdx":"Apache-2.0"}}],"tasks":[{"task_slug":"continuous-control","task_name":"Continuous Control"},{"task_slug":"imitation-learning","task_name":"Imitation Learning"},{"task_slug":"reinforcement-learning","task_name":"Reinforcement Learning"},{"task_slug":"reinforcement-learning-1","task_name":"Reinforcement Learning (RL)"},{"task_slug":"continuous-control","task_name":"continuous-control"},{"task_slug":"reinforcement-learning-2","task_name":"reinforcement-learning"}],"methods":[],"datasets_introduced":[],"methods_introduced":[],"results":[],"syntology":{"atlas_url":"https://app.syntology.ai/?focus=2108.04763","mcp":{"get_harvested_code_for_paper":{"arxiv_id":"2108.04763"}},"developers":"https://syntology.ai/developers","read_at":"2026-09-24T18:15:14+00:00","read_at_is":"when the build read Syntology's graph, not when any sample ran","claim":"Per-sample execution status on synthesized fixtures; not a correctness claim about the paper. Samples come from repositories linked to the paper, official or community; repo_kind says which.","repos":[{"provenance":"external:paperswithcode_snapshot_2025-07-28","url":"https://github.com/spotify-research/il-by-rl","reach":{"status":"ok","spdx":"Apache-2.0"}}],"summary":{"unverified":8},"by_repo_kind":{"official":{"samples":8,"ran":0,"repositories":1}},"repo_kind_vocabulary":{"official":"The archive marks this repository official for the paper","named_in_paper":"The archive records that the paper mentions this repository; it is not marked official","listed":"In the archive's code links for this paper, not marked official and not recorded as mentioned in the paper","found_in_text":"Syntology found this repository in the paper's own text; whether it is the authors' implementation is not asserted","community":"Not in the archive's code links for this paper; a community repository Syntology harvested"},"n_pointer_only_for_licence":0,"samples":[{"code_sha256_prefix":"16e011ab8b9dc3a6","entry":"evaluate","repo":"spotify-research/il-by-rl","repo_kind":"official","path":"d4rl_train.py","file_url":"https://github.com/spotify-research/il-by-rl/blob/HEAD/d4rl_train.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"16e011ab8b9dc3a6"}},{"code_sha256_prefix":"25bd681eec65f985","entry":"execute","repo":"spotify-research/il-by-rl","repo_kind":"official","path":"utils.py","file_url":"https://github.com/spotify-research/il-by-rl/blob/HEAD/utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"25bd681eec65f985"}},{"code_sha256_prefix":"58f5a0296ffac801","entry":"get_binary_reward","repo":"spotify-research/il-by-rl","repo_kind":"official","path":"train_il_functions.py","file_url":"https://github.com/spotify-research/il-by-rl/blob/HEAD/train_il_functions.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"58f5a0296ffac801"}},{"code_sha256_prefix":"56439c9c4f8ee150","entry":"get_small_dataset","repo":"spotify-research/il-by-rl","repo_kind":"official","path":"utils.py","file_url":"https://github.com/spotify-research/il-by-rl/blob/HEAD/utils.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"56439c9c4f8ee150"}},{"code_sha256_prefix":"b75128f3d89fb6e7","entry":"make_buffer_next","repo":"spotify-research/il-by-rl","repo_kind":"official","path":"train_il_functions.py","file_url":"https://github.com/spotify-research/il-by-rl/blob/HEAD/train_il_functions.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"b75128f3d89fb6e7"}},{"code_sha256_prefix":"315c8276b87bb7ac","entry":"optimization_step","repo":"spotify-research/il-by-rl","repo_kind":"official","path":"train_bc_functions.py","file_url":"https://github.com/spotify-research/il-by-rl/blob/HEAD/train_bc_functions.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"315c8276b87bb7ac"}},{"code_sha256_prefix":"c311e1212eabc873","entry":"update","repo":"spotify-research/il-by-rl","repo_kind":"official","path":"d4rl_train.py","file_url":"https://github.com/spotify-research/il-by-rl/blob/HEAD/d4rl_train.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"c311e1212eabc873"}},{"code_sha256_prefix":"52dbc718a25a63ce","entry":"update","repo":"spotify-research/il-by-rl","repo_kind":"official","path":"d4rl_train_sqil.py","file_url":"https://github.com/spotify-research/il-by-rl/blob/HEAD/d4rl_train_sqil.py","link_basis":"first_harvest_node","language":"python","status":"unverified","verification_level":0,"contract_check":null,"metamorphic_tier":null,"behaviour_fingerprint":false,"licence":"Apache-2.0","inline_ok":true,"mcp_get_code":{"code_sha256":"52dbc718a25a63ce"}}]},"arxiv_metadata":null,"syntology_extracted_results":null}