<?xml version="1.0" encoding="utf-8"?><feed xmlns="http://www.w3.org/2005/Atom" ><generator uri="https://jekyllrb.com/" version="3.10.0">Jekyll</generator><link href="https://theroboticsclub.github.io/2026-internship-Maryam_Tavasoli/feed.xml" rel="self" type="application/atom+xml" /><link href="https://theroboticsclub.github.io/2026-internship-Maryam_Tavasoli/" rel="alternate" type="text/html" /><updated>2026-11-25T12:01:01+00:00</updated><id>https://theroboticsclub.github.io/2026-internship-Maryam_Tavasoli/feed.xml</id><title type="html">Maryam Tavasoli | JdeRobot Internship 2026</title><subtitle>Weekly blog of my research internship at JdeRobot / RoboticsLab URJC: deep reinforcement learning for robot pick-and-place in MuJoCo, and how to explain what the learned policy does.</subtitle><author><name>Maryam Tavasoli</name></author><entry><title type="html">Week 1: kick-off and MuJoCo setup</title><link href="https://theroboticsclub.github.io/2026-internship-Maryam_Tavasoli/internship/setup/2026/11/25/week-1-kick-off-and-mujoco-setup.html" rel="alternate" type="text/html" title="Week 1: kick-off and MuJoCo setup" /><published>2026-11-25T00:00:00+00:00</published><updated>2026-11-25T00:00:00+00:00</updated><id>https://theroboticsclub.github.io/2026-internship-Maryam_Tavasoli/internship/setup/2026/11/25/week-1-kick-off-and-mujoco-setup</id><content type="html" xml:base="https://theroboticsclub.github.io/2026-internship-Maryam_Tavasoli/internship/setup/2026/11/25/week-1-kick-off-and-mujoco-setup.html"><![CDATA[<p>This first post covers the kick-off of the internship and the setup work: getting a working MuJoCo installation on my MacBook (M3 Pro) and agreeing on where to start.</p>

<h2 id="kick-off-call">Kick-off call</h2>

<p>On 18 November I had the kick-off call with Prof. José María Cañas and Dr. Luis Bote-Curiel. The main decisions:</p>

<ul>
  <li><strong>Topic:</strong> machine learning + explainability. The long-term goal is a scientific paper on explaining what a learned robot policy does.</li>
  <li><strong>Domain:</strong> a robot arm doing pick-and-place in MuJoCo. Autonomous driving in CARLA was the alternative, but it needs far more GPU power for rendering and training, so the manipulation task is the better fit for a laptop-first workflow.</li>
  <li><strong>Starting point:</strong> a <em>state-based</em> pick-and-place task trained with deep reinforcement learning (DRL), i.e. the policy observes joint positions, velocities and object/goal positions rather than camera images. A fellow student in the lab works on the <em>vision-based</em> version with <a href="https://github.com/mujocolab/mjlab">mjlab</a>, so the two lines complement each other.</li>
  <li><strong>Tools named:</strong> Gazebo, CARLA (autonomous driving) and MuJoCo (reinforcement learning).</li>
</ul>

<h2 id="mujoco-on-an-apple-silicon-mac">MuJoCo on an Apple-silicon Mac</h2>

<p>The first attempt used the newest MuJoCo (3.17). Physics and off-screen rendering worked, but the interactive viewer crashed immediately with <code class="language-plaintext highlighter-rouge">RuntimeError: Caught an unknown exception!</code>. Two things fixed it:</p>

<ol>
  <li><strong>Version.</strong> The lab’s RL code is built on mjlab, which pins <code class="language-plaintext highlighter-rouge">mujoco~=3.11.0</code>, so I installed MuJoCo <strong>3.11.0</strong> in its own virtual environment (Python 3.13) to stay compatible.</li>
  <li><strong>The macOS launch rule.</strong> On macOS the two viewer entry points need different interpreters:
    <ul>
      <li>the managed viewer, <code class="language-plaintext highlighter-rouge">python -m mujoco.viewer --mjcf=scene.xml</code>, must run with plain <code class="language-plaintext highlighter-rouge">python</code>;</li>
      <li>a script that calls <code class="language-plaintext highlighter-rouge">mujoco.viewer.launch_passive(...)</code> must run with <code class="language-plaintext highlighter-rouge">mjpython</code>.</li>
    </ul>

    <p>Mixing them up produces exactly that “unknown exception”. With the right launcher both viewers open fine.</p>
  </li>
</ol>

<p>To check how fast things run, I loaded the UR5e arm from <a href="https://github.com/google-deepmind/mujoco_menagerie">MuJoCo Menagerie</a> and measured:</p>

<table>
  <thead>
    <tr>
      <th>Check</th>
      <th>Result on the M3 Pro (CPU only)</th>
    </tr>
  </thead>
  <tbody>
    <tr>
      <td>Physics, UR5e scene, dt = 2 ms</td>
      <td>about 145k steps/s (roughly 290x real time)</td>
    </tr>
    <tr>
      <td>Off-screen rendering, 640x480</td>
      <td>about 80 fps</td>
    </tr>
    <tr>
      <td>Managed viewer and passive viewer</td>
      <td>both open</td>
    </tr>
  </tbody>
</table>

<p><img src="/2026-internship-Maryam_Tavasoli/assets/img/2026-11-25_ur5e_mujoco.png" alt="UR5e arm rendered off-screen in MuJoCo 3.11.0" /></p>

<p>That is plenty for state-based DRL experiments on the laptop. Anything GPU-heavy (mjlab / MuJoCo-Warp, large vision policies) will go to the lab’s GPU server once access is set up.</p>

<p>The check script is in the repository: <code class="language-plaintext highlighter-rouge">scripts/check_mujoco.py</code>.</p>

<h2 id="first-state-based-environment-already-running">First state-based environment already running</h2>

<p>As a last check this week I installed <a href="https://robotics.farama.org/">Gymnasium-Robotics</a> 1.4.2 next to MuJoCo 3.11.0 and stepped <code class="language-plaintext highlighter-rouge">FetchPickAndPlace-v4</code>: a 25-dimensional state observation plus 3-dimensional achieved/desired goals, a 4-dimensional action, sparse reward. It runs at about 2,000 environment steps per second on the CPU, and a short SAC + HER smoke test with Stable-Baselines3 on <code class="language-plaintext highlighter-rouge">FetchReach-v4</code> trains at roughly 200 steps per second including gradient updates. So the recommended stack from my first literature pass (goal-conditioned Fetch tasks + Hindsight Experience Replay) is usable on the laptop.</p>

<h2 id="plan-for-the-next-weeks">Plan for the next weeks</h2>

<ul>
  <li>Review the state of the art of DRL for state-based pick-and-place (goal-conditioned tasks such as the Fetch suite, Hindsight Experience Replay, off-policy algorithms like SAC/TD3, and more recent manipulation benchmarks).</li>
  <li>Get a first state-based pick-and-place environment running locally and train a baseline policy.</li>
  <li>Start mapping which explainability methods apply to a continuous-control policy with a low-dimensional state input.</li>
  <li>Read through my labmate’s mjlab-based project to align observation and action conventions.</li>
</ul>]]></content><author><name>Maryam Tavasoli</name></author><category term="internship" /><category term="setup" /><summary type="html"><![CDATA[Kick-off call, choosing the application domain, getting MuJoCo to run properly on an Apple-silicon Mac, and the plan for the first weeks.]]></summary></entry></feed>