title: How to define collision filter groups across model instances?
body: <p>When constructing a <code>MultiBodyPlant</code> from multiple <code>ModelInstances</code> each loaded from a separate URDF, is there a way to define collision filter groups to exclude collisions across model instances? In the <a href="https://github.com/RobotLocomotion/drake/blob/044b908dbde42c28bf04582f01e61ce3bb5ddce8/multibody/parsing/detail_urdf_parser.cc#L218-L244" rel="nofollow noreferrer">multibody URDF parser</a>, loading collision filter groups is restricted to the those present in the same model instance.</p>
  <p>What I would like to do is in URDF A specify:</p>
  <pre><code>  &lt;drake:collision_filter_group name=&quot;model_a_group&quot;&gt;
      &lt;drake:member link=&quot;link1&quot;/&gt;
      &lt;drake:member link=&quot;link2&quot;/&gt;
      &lt;drake:ignored_collision_filter_group name=&quot;model_b_group&quot;/&gt;
    &lt;/drake:collision_filter_group&gt;
  </code></pre>
  <p>and in URDF B specify:</p>
  <pre><code>  &lt;drake:collision_filter_group name=&quot;model_b_group&quot;&gt;
      &lt;drake:member link=&quot;link4&quot;/&gt;
      &lt;drake:member link=&quot;link5&quot;/&gt;
      &lt;drake:ignored_collision_filter_group name=&quot;model_a_group&quot;/&gt;
    &lt;/drake:collision_filter_group&gt;
  </code></pre>
  <p>But currently attempting to do this results in the following error:</p>
  <pre><code>abort: Failure at multibody/parsing/detail_urdf_parser.cc:238 in abort: 
  Failure at multibody/parsing/detail_urdf_parser.cc:238 in ParseCollisionFilterGroup(): 
  condition 'collision_filter_group_b != collision_filter_groups.end()' failed.
  </code></pre>