How jgitsol/robot_portfolio works
Project type and purpose
• This is an open-source, Python-based simulation tool (“robot_arm”) built on top of a reusable “robot_arm_simulator” library, plus a separate “LightPath” route-optimization module in the same mono-repo.
• The primary user-facing component is a PyBullet-based production line simulator with multiple 6-DOF arms, specialized grippers, a conveyor subsystem, and real-time 3D visualization.
File structure
• Top-level “v_beta/robot_arm_simulator” is a standalone Python package:
• config/ – simulation.yaml and loader
• src/robot_arm_simulator/… – core modules (config_loader, trajectory_planner, simulation, control, grippers, robots, utils)
• tests – unit tests for every sub-component
• Top-level “v_beta/src/robot_arm” is the demo package:
• demo.py, production_line.py, robot.py, grippers.py, ur5_robot.py – user scripts and classes that orchestrate the simulator library
• models/ – URDF and 3D files for robots, grippers, items
• “v_beta/src/lightpath” is a separate route-optimization engine (basic_use.py, core.py).
• Standard config files, setup.py, requirements.txt, pytest.ini, and CLI entry points are present.
Key insights from README
• The “robot_arm” CLI/demo loads a YAML config, spawns several robotic arms with different grippers on a conveyor, runs pick-and-place via PyBullet, and renders the scene.
• Dependencies: Python 3.8+, PyBullet, NumPy, PyYAML.
a. Main components
• User Interface / CLI (“robot-arm-demo”)
• Demo orchestration layer (“robot_arm” package)
• Simulation Core Library (“robot_arm_simulator”)
– Config Loader
– World & Environment (conveyor, sensors)
– Robot & Gripper classes
– Trajectory Planner / Control loop
– Physics engine wrapper (PyBullet)
– Utilities (logging, math)
• Model Repository (URDF, .glb files)
• Visualization & Rendering (PyBullet GUI)
• External Dependencies (PyBullet, NumPy, PyYAML)
b. Relationships and data flows
1. CLI → Demo orchestrator loads config via Config Loader
2. Demo instantiates Environment + Robots + Grippers
3. Orchestrator calls Simulation Core → hands off to PyBullet
4. Simulation loop:
– Sensors read world state → feed into Trajectory Planner
– Planner outputs joint commands → Control → actuates robot models in PyBullet
– PyBullet updates physics → updated world state
5. Visualization taps into PyBullet GUI each tick
6. At shutdown, orchestrator collects logs/results
c. Architectural patterns & design principles
• Modular library + thin orchestration layer
• Config-driven initialization (YAML)
• Clear separation: Model data (URDF) vs. code vs. config
• Strategy/plug-in pattern for grippers and robot kinematics
• Test-first design: extensive pytest suite for each module
d. Key technologies & libraries
• Python 3.8+
• PyBullet (physics + rendering)
• NumPy (math ops)
• PyYAML (config loader)
• Hypothesis / pytest (testing)