Skip to content

Commit

Permalink
Updating docs to d753bd4559210dd046a8b2adf5a4e9fb63c9417c
Browse files Browse the repository at this point in the history
  • Loading branch information
cbrxyz committed Feb 16, 2024
1 parent 505c573 commit 4af4a12
Show file tree
Hide file tree
Showing 35 changed files with 62 additions and 64 deletions.
20 changes: 10 additions & 10 deletions docs/_modules/axros/action.html

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion docs/_modules/axros/serviceclient.html
Original file line number Diff line number Diff line change
Expand Up @@ -219,7 +219,7 @@ <h1>Source code for axros.serviceclient</h1><div class="highlight"><pre>
<span class="k">while</span> <span class="kc">True</span><span class="p">:</span>
<span class="k">try</span><span class="p">:</span>
<span class="k">await</span> <span class="bp">self</span><span class="o">.</span><span class="n">_node_handle</span><span class="o">.</span><span class="n">master_proxy</span><span class="o">.</span><span class="n">lookup_service</span><span class="p">(</span><span class="bp">self</span><span class="o">.</span><span class="n">_name</span><span class="p">)</span>
<span class="k">except</span> <span class="p">(</span><span class="n">rosxmlrpc</span><span class="o">.</span><span class="n">XMLRPCException</span><span class="p">,</span> <span class="n">rosxmlrpc</span><span class="o">.</span><span class="n">ROSMasterError</span><span class="p">):</span>
<span class="k">except</span> <span class="n">rosxmlrpc</span><span class="o">.</span><span class="n">XMLRPCException</span><span class="p">:</span>
<span class="k">await</span> <span class="n">util</span><span class="o">.</span><span class="n">wall_sleep</span><span class="p">(</span><span class="mf">0.1</span><span class="p">)</span> <span class="c1"># XXX bad</span>
<span class="k">continue</span>
<span class="k">else</span><span class="p">:</span>
Expand Down
1 change: 1 addition & 0 deletions docs/_modules/mil_misc_tools/download.html
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,7 @@ <h1>Source code for mil_misc_tools.download</h1><div class="highlight"><pre>
<span class="sd">[3] Download a file via http</span>
<span class="sd"> http://stackoverflow.com/questions/22676</span>
<span class="sd">&quot;&quot;&quot;</span>

<span class="kn">import</span> <span class="nn">io</span> <span class="k">as</span> <span class="nn">StringIO</span>
<span class="kn">import</span> <span class="nn">os</span>
<span class="kn">import</span> <span class="nn">urllib.request</span>
Expand Down
4 changes: 2 additions & 2 deletions docs/_modules/mil_passive_sonar/scripts/triggering.html
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ <h1>Source code for mil_passive_sonar.scripts.triggering</h1><div class="highlig
<span class="bp">self</span><span class="o">.</span><span class="n">enabled</span> <span class="o">=</span> <span class="n">rospy</span><span class="o">.</span><span class="n">get_param</span><span class="p">(</span><span class="s2">&quot;~enable_on_launch&quot;</span><span class="p">)</span>

<span class="c1"># Attributes about our target frequency range</span>
<span class="c1"># target Frquency in Hz</span>
<span class="c1"># target Frequency in Hz</span>
<span class="bp">self</span><span class="o">.</span><span class="n">target</span> <span class="o">=</span> <span class="n">rospy</span><span class="o">.</span><span class="n">get_param</span><span class="p">(</span><span class="s2">&quot;~target_frequency&quot;</span><span class="p">)</span>
<span class="c1"># tolerance around that frequerncy in Hz</span>
<span class="n">tolerance</span> <span class="o">=</span> <span class="n">rospy</span><span class="o">.</span><span class="n">get_param</span><span class="p">(</span><span class="s2">&quot;~frequency_tolerance&quot;</span><span class="p">)</span>
Expand All @@ -201,7 +201,7 @@ <h1>Source code for mil_passive_sonar.scripts.triggering</h1><div class="highlig
<span class="bp">self</span><span class="o">.</span><span class="n">v_sound</span> <span class="o">=</span> <span class="n">rospy</span><span class="o">.</span><span class="n">get_param</span><span class="p">(</span><span class="s2">&quot;v_sound&quot;</span><span class="p">)</span>

<span class="c1"># Misc attributes</span>
<span class="c1"># minimum gradient of the max convolution wrt time to trigger a time of arivals calculation</span>
<span class="c1"># minimum gradient of the max convolution wrt time to trigger a time of arrivals calculation</span>
<span class="bp">self</span><span class="o">.</span><span class="n">threshold</span> <span class="o">=</span> <span class="n">rospy</span><span class="o">.</span><span class="n">get_param</span><span class="p">(</span><span class="s2">&quot;~threshold&quot;</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">trigger_offset</span> <span class="o">=</span> <span class="n">rospy</span><span class="o">.</span><span class="n">get_param</span><span class="p">(</span><span class="s2">&quot;~trigger_offset&quot;</span><span class="p">)</span>
<span class="c1"># how far after the triggering time to make upper bound of samples at triggering in sec</span>
Expand Down
1 change: 1 addition & 0 deletions docs/_modules/mil_ros_tools/cv_debug.html
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ <h1>Source code for mil_ros_tools.cv_debug</h1><div class="highlight"><pre>
<span></span><span class="sd">&quot;&quot;&quot;</span>
<span class="sd">Shows images for debugging purposes.</span>
<span class="sd">&quot;&quot;&quot;</span>

<span class="kn">import</span> <span class="nn">sys</span>
<span class="kn">from</span> <span class="nn">typing</span> <span class="kn">import</span> <span class="n">Optional</span>

Expand Down
2 changes: 1 addition & 1 deletion docs/_modules/mil_ros_tools/image_helpers.html
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@ <h1>Source code for mil_ros_tools.image_helpers</h1><div class="highlight"><pre>
<span class="sd"> last_image_time (genpy.Time): The time of the last image received.</span>
<span class="sd"> im_sub (rospy.Subscriber): The subscriber to the image topic. The topic</span>
<span class="sd"> name and queue size are received through the constructor.</span>
<span class="sd"> info_sub (rospy.Susbcriber): The subscriber to the camera info topic.</span>
<span class="sd"> info_sub (rospy.Subscriber): The subscriber to the camera info topic.</span>
<span class="sd"> The topic name is derived from the root of the supplied topic and the</span>
<span class="sd"> queue size is derived from the constructor.</span>
<span class="sd"> bridge (CvBridge): The bridge between OpenCV and ROS.</span>
Expand Down
1 change: 1 addition & 0 deletions docs/_modules/mil_ros_tools/init_helpers.html
Original file line number Diff line number Diff line change
Expand Up @@ -82,6 +82,7 @@ <h1>Source code for mil_ros_tools.init_helpers</h1><div class="highlight"><pre>
<span class="sd">This module provides functions which help to ensure that resources are available</span>
<span class="sd">when needed.</span>
<span class="sd">&quot;&quot;&quot;</span>

<span class="kn">import</span> <span class="nn">time</span>
<span class="kn">from</span> <span class="nn">typing</span> <span class="kn">import</span> <span class="n">Any</span><span class="p">,</span> <span class="n">Optional</span>

Expand Down
12 changes: 4 additions & 8 deletions docs/_modules/mil_usb_to_can/sub8/utils.html
Original file line number Diff line number Diff line change
Expand Up @@ -194,13 +194,11 @@ <h1>Source code for mil_usb_to_can.sub8.utils</h1><div class="highlight"><pre>

<span class="nd">@overload</span>
<span class="nd">@classmethod</span>
<span class="k">def</span> <span class="nf">_unpack_payload</span><span class="p">(</span><span class="bp">cls</span><span class="p">,</span> <span class="n">data</span><span class="p">:</span> <span class="n">Literal</span><span class="p">[</span><span class="sa">b</span><span class="s2">&quot;&quot;</span><span class="p">])</span> <span class="o">-&gt;</span> <span class="kc">None</span><span class="p">:</span>
<span class="o">...</span>
<span class="k">def</span> <span class="nf">_unpack_payload</span><span class="p">(</span><span class="bp">cls</span><span class="p">,</span> <span class="n">data</span><span class="p">:</span> <span class="n">Literal</span><span class="p">[</span><span class="sa">b</span><span class="s2">&quot;&quot;</span><span class="p">])</span> <span class="o">-&gt;</span> <span class="kc">None</span><span class="p">:</span> <span class="o">...</span>

<span class="nd">@overload</span>
<span class="nd">@classmethod</span>
<span class="k">def</span> <span class="nf">_unpack_payload</span><span class="p">(</span><span class="bp">cls</span><span class="p">,</span> <span class="n">data</span><span class="p">:</span> <span class="nb">bytes</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">bytes</span><span class="p">:</span>
<span class="o">...</span>
<span class="k">def</span> <span class="nf">_unpack_payload</span><span class="p">(</span><span class="bp">cls</span><span class="p">,</span> <span class="n">data</span><span class="p">:</span> <span class="nb">bytes</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">bytes</span><span class="p">:</span> <span class="o">...</span>

<span class="nd">@classmethod</span>
<span class="k">def</span> <span class="nf">_unpack_payload</span><span class="p">(</span><span class="bp">cls</span><span class="p">,</span> <span class="n">data</span><span class="p">:</span> <span class="nb">bytes</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="nb">bytes</span> <span class="o">|</span> <span class="kc">None</span><span class="p">:</span>
Expand Down Expand Up @@ -535,13 +533,11 @@ <h1>Source code for mil_usb_to_can.sub8.utils</h1><div class="highlight"><pre>

<span class="nd">@overload</span>
<span class="nd">@classmethod</span>
<span class="k">def</span> <span class="nf">from_bytes</span><span class="p">(</span><span class="bp">cls</span><span class="p">,</span> <span class="n">data</span><span class="p">:</span> <span class="n">Literal</span><span class="p">[</span><span class="sa">b</span><span class="s2">&quot;&quot;</span><span class="p">])</span> <span class="o">-&gt;</span> <span class="kc">None</span><span class="p">:</span>
<span class="o">...</span>
<span class="k">def</span> <span class="nf">from_bytes</span><span class="p">(</span><span class="bp">cls</span><span class="p">,</span> <span class="n">data</span><span class="p">:</span> <span class="n">Literal</span><span class="p">[</span><span class="sa">b</span><span class="s2">&quot;&quot;</span><span class="p">])</span> <span class="o">-&gt;</span> <span class="kc">None</span><span class="p">:</span> <span class="o">...</span>

<span class="nd">@overload</span>
<span class="nd">@classmethod</span>
<span class="k">def</span> <span class="nf">from_bytes</span><span class="p">(</span><span class="bp">cls</span><span class="p">:</span> <span class="nb">type</span><span class="p">[</span><span class="n">T</span><span class="p">],</span> <span class="n">data</span><span class="p">:</span> <span class="nb">bytes</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="n">T</span><span class="p">:</span>
<span class="o">...</span>
<span class="k">def</span> <span class="nf">from_bytes</span><span class="p">(</span><span class="bp">cls</span><span class="p">:</span> <span class="nb">type</span><span class="p">[</span><span class="n">T</span><span class="p">],</span> <span class="n">data</span><span class="p">:</span> <span class="nb">bytes</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="n">T</span><span class="p">:</span> <span class="o">...</span>

<span class="nd">@classmethod</span>
<span class="k">def</span> <span class="nf">from_bytes</span><span class="p">(</span><span class="bp">cls</span><span class="p">:</span> <span class="nb">type</span><span class="p">[</span><span class="n">T</span><span class="p">],</span> <span class="n">data</span><span class="p">:</span> <span class="nb">bytes</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="n">T</span> <span class="o">|</span> <span class="kc">None</span><span class="p">:</span>
Expand Down
2 changes: 1 addition & 1 deletion docs/_modules/mil_vision_tools/color_classifier.html
Original file line number Diff line number Diff line change
Expand Up @@ -174,7 +174,7 @@ <h1>Source code for mil_vision_tools.color_classifier</h1><div class="highlight"

<div class="viewcode-block" id="ContourClassifier.feature_probabilities"><a class="viewcode-back" href="../../reference/vision.html#mil_vision_tools.ContourClassifier.feature_probabilities">[docs]</a> <span class="k">def</span> <span class="nf">feature_probabilities</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">features</span><span class="p">:</span> <span class="n">np</span><span class="o">.</span><span class="n">ndarray</span><span class="p">)</span> <span class="o">-&gt;</span> <span class="n">List</span><span class="p">[</span><span class="nb">float</span><span class="p">]:</span>
<span class="w"> </span><span class="sd">&quot;&quot;&quot;</span>
<span class="sd"> Allows child classes to give probabilties for each possible class given</span>
<span class="sd"> Allows child classes to give probabilities for each possible class given</span>
<span class="sd"> a features vector, instead of just one classification. By default,</span>
<span class="sd"> gives 1.0 to classified class and 0.0 to others.</span>

Expand Down
14 changes: 7 additions & 7 deletions docs/_modules/mil_vision_tools/shape_finder.html
Original file line number Diff line number Diff line change
Expand Up @@ -293,7 +293,7 @@ <h1>Source code for mil_vision_tools.shape_finder</h1><div class="highlight"><pr
<span class="sd"> cam (Optional[PinholeCameraModel]): The camera model.</span>
<span class="sd"> rectified (bool): If ``cam`` is set, set True if corners were found in an</span>
<span class="sd"> already rectified image (image_rect_color topic).</span>
<span class="sd"> instrinsics (np.ndarray): Camera intrinisic matrix.</span>
<span class="sd"> intrinsics (np.ndarray): Camera intrinisic matrix.</span>
<span class="sd"> dist_coeffs (np.ndarray): Camera distortion coefficients.</span>

<span class="sd"> Returns:</span>
Expand Down Expand Up @@ -384,12 +384,12 @@ <h1>Source code for mil_vision_tools.shape_finder</h1><div class="highlight"><pr
<span class="bp">self</span><span class="o">.</span><span class="n">model_2D</span> <span class="o">=</span> <span class="n">np</span><span class="o">.</span><span class="n">zeros</span><span class="p">((</span><span class="mi">50</span><span class="p">,</span> <span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">),</span> <span class="n">dtype</span><span class="o">=</span><span class="n">np</span><span class="o">.</span><span class="n">int</span><span class="p">)</span>
<span class="c1"># Approximate an ellipse with 50 points, so that verify_contour is reasonable fast still</span>
<span class="k">for</span> <span class="n">idx</span><span class="p">,</span> <span class="n">theta</span> <span class="ow">in</span> <span class="nb">enumerate</span><span class="p">(</span><span class="n">np</span><span class="o">.</span><span class="n">linspace</span><span class="p">(</span><span class="mf">0.0</span><span class="p">,</span> <span class="mf">2.0</span> <span class="o">*</span> <span class="n">np</span><span class="o">.</span><span class="n">pi</span><span class="p">,</span> <span class="n">num</span><span class="o">=</span><span class="mi">50</span><span class="p">)):</span>
<span class="bp">self</span><span class="o">.</span><span class="n">model_2D</span><span class="p">[</span><span class="n">idx</span><span class="p">][</span><span class="mi">0</span><span class="p">][</span>
<span class="mi">0</span>
<span class="p">]</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">length</span> <span class="o">*</span> <span class="mf">0.5</span> <span class="o">*</span> <span class="n">scale</span> <span class="o">+</span> <span class="bp">self</span><span class="o">.</span><span class="n">length</span> <span class="o">*</span> <span class="mf">0.5</span> <span class="o">*</span> <span class="n">scale</span> <span class="o">*</span> <span class="n">np</span><span class="o">.</span><span class="n">cos</span><span class="p">(</span><span class="n">theta</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">model_2D</span><span class="p">[</span><span class="n">idx</span><span class="p">][</span><span class="mi">0</span><span class="p">][</span>
<span class="mi">1</span>
<span class="p">]</span> <span class="o">=</span> <span class="bp">self</span><span class="o">.</span><span class="n">width</span> <span class="o">*</span> <span class="mf">0.5</span> <span class="o">*</span> <span class="n">scale</span> <span class="o">+</span> <span class="bp">self</span><span class="o">.</span><span class="n">width</span> <span class="o">*</span> <span class="mf">0.5</span> <span class="o">*</span> <span class="n">scale</span> <span class="o">*</span> <span class="n">np</span><span class="o">.</span><span class="n">sin</span><span class="p">(</span><span class="n">theta</span><span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">model_2D</span><span class="p">[</span><span class="n">idx</span><span class="p">][</span><span class="mi">0</span><span class="p">][</span><span class="mi">0</span><span class="p">]</span> <span class="o">=</span> <span class="p">(</span>
<span class="bp">self</span><span class="o">.</span><span class="n">length</span> <span class="o">*</span> <span class="mf">0.5</span> <span class="o">*</span> <span class="n">scale</span> <span class="o">+</span> <span class="bp">self</span><span class="o">.</span><span class="n">length</span> <span class="o">*</span> <span class="mf">0.5</span> <span class="o">*</span> <span class="n">scale</span> <span class="o">*</span> <span class="n">np</span><span class="o">.</span><span class="n">cos</span><span class="p">(</span><span class="n">theta</span><span class="p">)</span>
<span class="p">)</span>
<span class="bp">self</span><span class="o">.</span><span class="n">model_2D</span><span class="p">[</span><span class="n">idx</span><span class="p">][</span><span class="mi">0</span><span class="p">][</span><span class="mi">1</span><span class="p">]</span> <span class="o">=</span> <span class="p">(</span>
<span class="bp">self</span><span class="o">.</span><span class="n">width</span> <span class="o">*</span> <span class="mf">0.5</span> <span class="o">*</span> <span class="n">scale</span> <span class="o">+</span> <span class="bp">self</span><span class="o">.</span><span class="n">width</span> <span class="o">*</span> <span class="mf">0.5</span> <span class="o">*</span> <span class="n">scale</span> <span class="o">*</span> <span class="n">np</span><span class="o">.</span><span class="n">sin</span><span class="p">(</span><span class="n">theta</span><span class="p">)</span>
<span class="p">)</span>

<span class="k">def</span> <span class="nf">get_corners</span><span class="p">(</span><span class="bp">self</span><span class="p">,</span> <span class="n">contour</span><span class="p">,</span> <span class="n">debug_image</span><span class="o">=</span><span class="kc">None</span><span class="p">):</span>
<span class="w"> </span><span class="sd">&quot;&quot;&quot;</span>
Expand Down
2 changes: 1 addition & 1 deletion docs/_modules/mil_vision_tools/vision_node.html
Original file line number Diff line number Diff line change
Expand Up @@ -107,7 +107,7 @@ <h1>Source code for mil_vision_tools.vision_node</h1><div class="highlight"><pre
<span class="sd"> is needed/available in your application.</span>

<span class="sd"> Args:</span>
<span class="sd"> name (str): Name of the identifed object.</span>
<span class="sd"> name (str): Name of the identified object.</span>
<span class="sd"> attributes (str): Attributes to attach to message, the purpose and value</span>
<span class="sd"> of this attribute will vary by application. Defaults to an empty string.</span>
<span class="sd"> confidence (Optional[float]): Float between 0 and 1 describing the confidence</span>
Expand Down
Loading

0 comments on commit 4af4a12

Please sign in to comment.