{"id":28268852,"url":"https://github.com/iory/urdfeus","last_synced_at":"2026-02-20T17:01:54.404Z","repository":{"id":204280592,"uuid":"711194508","full_name":"iory/urdfeus","owner":"iory","description":"URDF converter for euslisp","archived":false,"fork":false,"pushed_at":"2025-10-31T12:20:38.000Z","size":469,"stargazers_count":1,"open_issues_count":0,"forks_count":2,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-10-31T12:37:13.045Z","etag":null,"topics":["euslisp","hacktoberfest","ros","urdf"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/iory.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","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,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2023-10-28T13:51:13.000Z","updated_at":"2025-10-31T12:19:09.000Z","dependencies_parsed_at":null,"dependency_job_id":"e4ce15e4-9f81-4e89-9488-9593f27f9ed3","html_url":"https://github.com/iory/urdfeus","commit_stats":null,"previous_names":["iory/urdfeus"],"tags_count":30,"template":false,"template_full_name":null,"purl":"pkg:github/iory/urdfeus","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iory%2Furdfeus","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iory%2Furdfeus/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iory%2Furdfeus/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iory%2Furdfeus/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/iory","download_url":"https://codeload.github.com/iory/urdfeus/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/iory%2Furdfeus/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":29658167,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-02-20T16:33:43.953Z","status":"ssl_error","status_checked_at":"2026-02-20T16:33:43.598Z","response_time":59,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"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":["euslisp","hacktoberfest","ros","urdf"],"created_at":"2025-05-20T15:13:36.625Z","updated_at":"2026-02-20T17:01:54.398Z","avatar_url":"https://github.com/iory.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# urdfeus\n\n![PyPI](https://img.shields.io/pypi/v/urdfeus.svg)\n![Python Versions](https://img.shields.io/pypi/pyversions/urdfeus.svg)\n[![Build Status](https://github.com/iory/urdfeus/actions/workflows/test.yml/badge.svg?branch=main)](https://github.com/iory/urdfeus/actions)\n\nURDFファイルをEusLispコードに変換するPythonライブラリ\n\n## 概要\n\n`urdfeus`は、ロボット記述ファイル（URDF）をEusLispのロボットモデル定義に変換するツールです。ROS環境で使用されるURDFファイルを、EusLispプログラミング環境で利用できる形式に変換できます。\n\n![URDF to EusLisp conversion](docs/urdf2eus-image.png)\n\n## インストール\n\n```bash\npip install urdfeus\n```\n\n開発版をインストールする場合：\n\n```bash\ngit clone https://github.com/iory/urdfeus.git\ncd urdfeus\npip install -e .\n```\n\n## 使用方法\n\n### コマンドライン\n\n```bash\n# 基本的な変換\nurdf2eus robot.urdf robot.l\n\n# YAMLファイルと一緒に変換\nurdf2eus robot.urdf robot.l --yaml-path robot.yaml\n\n# カスタムロボット名を指定\nurdf2eus robot.urdf robot.l --name my_robot\n\n# メッシュ簡素化オプション付き\nurdf2eus robot.urdf robot.l --voxel-size 0.01\n```\n\n### Pythonスクリプト\n\n```python\nfrom urdfeus.urdf2eus import urdf2eus\n\n# URDFファイルをEusLispに変換\nwith open('robot.l', 'w') as f:\n    urdf2eus('robot.urdf', fp=f)\n\n# YAMLファイルと一緒に変換\nwith open('robot.l', 'w') as f:\n    urdf2eus('robot.urdf', 'robot.yaml', fp=f)\n\n# カスタムロボット名を指定\nwith open('robot.l', 'w') as f:\n    urdf2eus('robot.urdf', robot_name='my_robot', fp=f)\n```\n\n### 生成されたEusLispファイルの使用\n\n```lisp\n;; EusLisp環境での使用例\n(load \"robot.l\")\n(setq *robot* (robot))  ; URDFのロボット名または--nameで指定した名前\n(send *robot* :angle-vector)\n\n;; カスタム名を指定した場合\n(load \"robot.l\")\n(setq *robot* (my_robot))  ; --name my_robot で生成した場合\n(send *robot* :angle-vector)\n```\n\n### ロボット名の制約\n\n`--name`オプションで指定するロボット名は、EusLispの識別子として有効である必要があります：\n\n- 文字または`_`で始まる\n- 文字、数字、`_`、`-`のみ使用可能\n- EusLispの予約語（`if`, `defun`, `nil`など）は使用不可\n- 空文字列やスペースを含む名前は使用不可\n\n**有効な例**: `my_robot`, `robot-v1`, `MyRobot`, `_robot`, `robot123`\n**無効な例**: `123robot`, `robot name`, `robot.name`, `if`, `defun`\n\n## YAMLファイル\n\nロボットの関節グループ、エンドエフェクタ、初期ポーズを設定できます。\n\n### PR2ロボットの設定例\n\n実際の[PR2設定ファイル](https://github.com/iory/urdfeus/blob/main/tests/urdfeus_tests/pr2.yaml)を参考にした例：\n\n```yaml\n# 関節グループの定義\ntorso:\n  - torso_lift_joint : torso-waist-z\n\nlarm:\n  - l_shoulder_pan_joint   : larm-collar-y\n  - l_shoulder_lift_joint  : larm-shoulder-p\n  - l_upper_arm_roll_joint : larm-shoulder-r\n  - l_elbow_flex_joint     : larm-elbow-p\n  - l_forearm_roll_joint   : larm-elbow-r\n  - l_wrist_flex_joint     : larm-wrist-p\n  - l_wrist_roll_joint     : larm-wrist-r\n\nrarm:\n  - r_shoulder_pan_joint   : rarm-collar-y\n  - r_shoulder_lift_joint  : rarm-shoulder-p\n  - r_upper_arm_roll_joint : rarm-shoulder-r\n  - r_elbow_flex_joint     : rarm-elbow-p\n  - r_forearm_roll_joint   : rarm-elbow-r\n  - r_wrist_flex_joint     : rarm-wrist-p\n  - r_wrist_roll_joint     : rarm-wrist-r\n\nhead:\n  - head_pan_joint  : head-neck-y\n  - head_tilt_joint : head-neck-p\n\n# エンドエフェクタ座標系\nlarm-end-coords: \n  parent : l_gripper_tool_frame\n  rotate : [0, 1, 0, 0]\n\nrarm-end-coords:\n  parent : r_gripper_tool_frame\n  rotate : [0, 1, 0, 0]\n\nhead-end-coords:\n  translate : [0.08, 0, 0.13]\n  rotate    : [0, 1, 0, 90]\n\n# 事前定義ポーズ\nangle-vector:\n  reset-manip-pose : [300.0, 75.0, 50.0, 110.0, -110.0, -20.0, -10.0, -10.0, -75.0, 50.0, -110.0, -110.0, 20.0, -10.0, -10.0, 0.0, 50.0]\n  reset-pose : [50.0, 60.0, 74.0, 70.0, -120.0, 20.0, -30.0, 180.0, -60.0, 74.0, -70.0, -120.0, -20.0, -30.0, 180.0, 0.0, 0.0]\n```\n\n### グループ定義の効果\n\nYAMLファイルでグループを定義すると、EusLispで以下のようなメソッドが使用できるようになります：\n\n```lisp\n;; PR2ロボットの例\n(setq *robot* (pr2))\n\n;; 右腕の現在の関節角度を取得\n(send *robot* :rarm :angle-vector)\n;; =\u003e #f(-60.0 74.0 -70.0 -120.0 -20.0 -30.0 180.0)\n\n;; 右腕の関節リストを取得\n(send *robot* :rarm :joint-list)\n;; =\u003e (#\u003crotational-joint r_shoulder_pan_joint\u003e \n;;     #\u003crotational-joint r_shoulder_lift_joint\u003e ...)\n\n;; 関節名を取得\n(send-all (send *robot* :rarm :joint-list) :name)\n;; =\u003e (\"r_shoulder_pan_joint\" \"r_shoulder_lift_joint\" \n;;     \"r_upper_arm_roll_joint\" \"r_elbow_flex_joint\" ...)\n\n;; 右腕の関節角度を設定\n(send *robot* :rarm :angle-vector #f(0 0 0 -90 0 0 0))\n\n;; 事前定義ポーズの使用\n(send *robot* :reset-pose)\n```\n\n### 設定項目の詳細\n\n#### 関節グループ\n- `グループ名`: ロボットの部位名（rarm, larm, head など）\n- `関節名 : EusLisp関節名`: URDFの関節名とEusLispでの関節名のマッピング\n\n#### エンドエフェクタ座標系\n- `parent`: 座標系を取り付ける親リンク名\n- `translate`: [x, y, z] 平行移動（メートル単位）\n- `rotate`: [x, y, z, angle] 回転軸ベクトルと角度（度単位）\n\n#### 事前定義ポーズ\n- `angle-vector`: ポーズ名と対応する関節角度リスト\n- 関節角度は度単位で指定\n- 関節の順序はYAMLファイル内の関節グループの定義順序に従う\n\n## 依存関係\n\n- Python 3.6+\n- scikit-robot\n- trimesh\n- numpy\n\n## ライセンス\n\nMIT License\n\n## 貢献\n\nプルリクエストやイシューの報告を歓迎します。\n\n## 関連プロジェクト\n\n- [scikit-robot](https://github.com/iory/scikit-robot) - Pythonロボットモデリングライブラリ\n- [EusLisp](https://github.com/euslisp/EusLisp) - Lispベースのロボットプログラミング言語","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiory%2Furdfeus","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fiory%2Furdfeus","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fiory%2Furdfeus/lists"}