Parcourir la source

Update bilateral kernels

Jérôme BUISINE il y a 4 ans
Parent
commit
fd79752721
44 fichiers modifiés avec 222 ajouts et 125 suppressions
  1. BIN
      docs/build/doctrees/environment.pickle
  2. BIN
      docs/build/doctrees/ipfml/ipfml.filters.kernels.doctree
  3. 1 1
      docs/build/html/.buildinfo
  4. 2 2
      docs/build/html/_modules/index.html
  5. 2 2
      docs/build/html/_modules/ipfml/exceptions.html
  6. 2 2
      docs/build/html/_modules/ipfml/filters/convolution.html
  7. 51 14
      docs/build/html/_modules/ipfml/filters/kernels.html
  8. 2 2
      docs/build/html/_modules/ipfml/filters/noise.html
  9. 2 2
      docs/build/html/_modules/ipfml/iqa/fr.html
  10. 2 2
      docs/build/html/_modules/ipfml/metrics.html
  11. 2 2
      docs/build/html/_modules/ipfml/processing/compression.html
  12. 2 2
      docs/build/html/_modules/ipfml/processing/movement.html
  13. 2 2
      docs/build/html/_modules/ipfml/processing/reconstruction.html
  14. 2 2
      docs/build/html/_modules/ipfml/processing/segmentation.html
  15. 2 2
      docs/build/html/_modules/ipfml/processing/transform.html
  16. 2 2
      docs/build/html/_modules/ipfml/utils.html
  17. 2 1
      docs/build/html/_sources/ipfml/ipfml.filters.kernels.rst.txt
  18. 1 1
      docs/build/html/_static/documentation_options.js
  19. 2 2
      docs/build/html/contributing.html
  20. 2 2
      docs/build/html/description.html
  21. 2 2
      docs/build/html/examples.html
  22. 8 13
      docs/build/html/genindex.html
  23. 2 2
      docs/build/html/index.html
  24. 2 2
      docs/build/html/ipfml.html
  25. 2 2
      docs/build/html/ipfml/ipfml.exceptions.html
  26. 2 2
      docs/build/html/ipfml/ipfml.filters.convolution.html
  27. 45 19
      docs/build/html/ipfml/ipfml.filters.kernels.html
  28. 2 2
      docs/build/html/ipfml/ipfml.filters.noise.html
  29. 2 2
      docs/build/html/ipfml/ipfml.iqa.fr.html
  30. 2 2
      docs/build/html/ipfml/ipfml.metrics.html
  31. 2 2
      docs/build/html/ipfml/ipfml.processing.compression.html
  32. 2 2
      docs/build/html/ipfml/ipfml.processing.movement.html
  33. 2 2
      docs/build/html/ipfml/ipfml.processing.reconstruction.html
  34. 2 2
      docs/build/html/ipfml/ipfml.processing.segmentation.html
  35. 2 2
      docs/build/html/ipfml/ipfml.processing.transform.html
  36. 2 2
      docs/build/html/ipfml/ipfml.utils.html
  37. BIN
      docs/build/html/objects.inv
  38. 2 2
      docs/build/html/py-modindex.html
  39. 2 2
      docs/build/html/search.html
  40. 1 1
      docs/build/html/searchindex.js
  41. 2 2
      docs/source/conf.py
  42. 2 1
      docs/source/ipfml/ipfml.filters.kernels.rst
  43. 48 11
      ipfml/filters/kernels.py
  44. 1 1
      setup.py

BIN
docs/build/doctrees/environment.pickle


BIN
docs/build/doctrees/ipfml/ipfml.filters.kernels.doctree


+ 1 - 1
docs/build/html/.buildinfo

@@ -1,4 +1,4 @@
 # Sphinx build info version 1
 # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
-config: 6caa61d79723a7d62ecdb97776cf8275
+config: 9a792b9eb44bdcf4b91ffb436b8dcc12
 tags: 645f666f9bcd5a90fca523b33c5a78b7

+ 2 - 2
docs/build/html/_modules/index.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Overview: module code &mdash; ipfml v0.4.6 documentation</title>
+  <title>Overview: module code &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/exceptions.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.exceptions &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.exceptions &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/filters/convolution.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.filters.convolution &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.filters.convolution &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 51 - 14
docs/build/html/_modules/ipfml/filters/kernels.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.filters.kernels &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.filters.kernels &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           
@@ -257,8 +257,8 @@
     <span class="k">return</span> <span class="p">(</span><span class="n">errors</span><span class="o">.</span><span class="n">max</span><span class="p">()</span> <span class="o">-</span> <span class="n">errors</span><span class="o">.</span><span class="n">min</span><span class="p">())</span></div>
 
 
-<div class="viewcode-block" id="bilateral_diff"><a class="viewcode-back" href="../../../ipfml/ipfml.filters.kernels.html#ipfml.filters.kernels.bilateral_diff">[docs]</a><span class="k">def</span> <span class="nf">bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">,</span> <span class="n">func</span><span class="o">=</span><span class="nb">max</span><span class="p">):</span>
-    <span class="sd">&quot;&quot;&quot;Bilaeral difference kernel to use with convolution process on image</span>
+<span class="k">def</span> <span class="nf">_bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">,</span> <span class="n">func</span><span class="p">):</span>
+    <span class="sd">&quot;&quot;&quot;Main bilateral difference kernel to use with convolution process on image</span>
 <span class="sd">       Apply difference pixel to pixel and keep max on min difference before applying mean</span>
 
 <span class="sd">    Args:</span>
@@ -267,15 +267,6 @@
 
 <span class="sd">    Returns:</span>
 <span class="sd">        mean of max or min difference of pixels</span>
-
-<span class="sd">    Example:</span>
-
-<span class="sd">    &gt;&gt;&gt; from ipfml.filters.kernels import bilateral_diff</span>
-<span class="sd">    &gt;&gt;&gt; import numpy as np</span>
-<span class="sd">    &gt;&gt;&gt; window = np.arange(9).reshape([3, 3])</span>
-<span class="sd">    &gt;&gt;&gt; result = bilateral_diff(window)</span>
-<span class="sd">    &gt;&gt;&gt; result</span>
-<span class="sd">    3.0</span>
 <span class="sd">    &quot;&quot;&quot;</span>
 
     <span class="n">window</span> <span class="o">=</span> <span class="n">np</span><span class="o">.</span><span class="n">array</span><span class="p">(</span><span class="n">window</span><span class="p">)</span>
@@ -325,7 +316,53 @@
     <span class="n">row_diff</span> <span class="o">=</span> <span class="nb">sum</span><span class="p">(</span><span class="n">total_row_diff_list</span><span class="p">)</span> <span class="o">/</span> <span class="nb">len</span><span class="p">(</span><span class="n">total_row_diff_list</span><span class="p">)</span>
     <span class="n">col_diff</span> <span class="o">=</span> <span class="nb">sum</span><span class="p">(</span><span class="n">total_col_diff_list</span><span class="p">)</span> <span class="o">/</span> <span class="nb">len</span><span class="p">(</span><span class="n">total_col_diff_list</span><span class="p">)</span>
 
-    <span class="k">return</span> <span class="n">func</span><span class="p">(</span><span class="n">row_diff</span><span class="p">,</span> <span class="n">col_diff</span><span class="p">)</span></div>
+    <span class="k">return</span> <span class="n">func</span><span class="p">(</span><span class="n">row_diff</span><span class="p">,</span> <span class="n">col_diff</span><span class="p">)</span>
+
+
+<div class="viewcode-block" id="max_bilateral_diff"><a class="viewcode-back" href="../../../ipfml/ipfml.filters.kernels.html#ipfml.filters.kernels.max_bilateral_diff">[docs]</a><span class="k">def</span> <span class="nf">max_bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">):</span>
+    <span class="sd">&quot;&quot;&quot;Bilateral difference kernel to use with convolution process on image</span>
+<span class="sd">       Apply difference pixel to pixel and keep max difference before applying mean</span>
+
+<span class="sd">    Args:</span>
+<span class="sd">        window: the window part to use from image</span>
+
+<span class="sd">    Returns:</span>
+<span class="sd">        mean of max difference of pixels</span>
+
+<span class="sd">    Example:</span>
+
+<span class="sd">    &gt;&gt;&gt; from ipfml.filters.kernels import max_bilateral_diff</span>
+<span class="sd">    &gt;&gt;&gt; import numpy as np</span>
+<span class="sd">    &gt;&gt;&gt; window = np.arange(9).reshape([3, 3])</span>
+<span class="sd">    &gt;&gt;&gt; result = max_bilateral_diff(window)</span>
+<span class="sd">    &gt;&gt;&gt; result</span>
+<span class="sd">    3.0</span>
+<span class="sd">    &quot;&quot;&quot;</span>
+
+    <span class="k">return</span> <span class="n">_bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">,</span> <span class="nb">max</span><span class="p">)</span></div>
+
+
+<div class="viewcode-block" id="min_bilateral_diff"><a class="viewcode-back" href="../../../ipfml/ipfml.filters.kernels.html#ipfml.filters.kernels.min_bilateral_diff">[docs]</a><span class="k">def</span> <span class="nf">min_bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">):</span>
+    <span class="sd">&quot;&quot;&quot;Bilateral difference kernel to use with convolution process on image</span>
+<span class="sd">       Apply difference pixel to pixel and keep min difference before applying mean</span>
+
+<span class="sd">    Args:</span>
+<span class="sd">        window: the window part to use from image</span>
+
+<span class="sd">    Returns:</span>
+<span class="sd">        mean of min difference of pixels</span>
+
+<span class="sd">    Example:</span>
+
+<span class="sd">    &gt;&gt;&gt; from ipfml.filters.kernels import min_bilateral_diff</span>
+<span class="sd">    &gt;&gt;&gt; import numpy as np</span>
+<span class="sd">    &gt;&gt;&gt; window = np.arange(9).reshape([3, 3])</span>
+<span class="sd">    &gt;&gt;&gt; result = min_bilateral_diff(window)</span>
+<span class="sd">    &gt;&gt;&gt; result</span>
+<span class="sd">    1.0</span>
+<span class="sd">    &quot;&quot;&quot;</span>
+
+    <span class="k">return</span> <span class="n">_bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">,</span> <span class="nb">min</span><span class="p">)</span></div>
 </pre></div>
 
            </div>

+ 2 - 2
docs/build/html/_modules/ipfml/filters/noise.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.filters.noise &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.filters.noise &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/iqa/fr.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.iqa.fr &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.iqa.fr &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/metrics.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.metrics &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.metrics &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/processing/compression.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.compression &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.compression &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/processing/movement.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.movement &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.movement &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/processing/reconstruction.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.reconstruction &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.reconstruction &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/processing/segmentation.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.segmentation &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.segmentation &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/processing/transform.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.transform &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.transform &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/_modules/ipfml/utils.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.utils &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.utils &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 1
docs/build/html/_sources/ipfml/ipfml.filters.kernels.rst.txt

@@ -9,7 +9,8 @@ ipfml.filters.kernels
 
    .. autosummary::
    
-      bilateral_diff
+      max_bilateral_diff
+      min_bilateral_diff
       plane_max_error
       plane_mean
    

+ 1 - 1
docs/build/html/_static/documentation_options.js

@@ -1,6 +1,6 @@
 var DOCUMENTATION_OPTIONS = {
     URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'),
-    VERSION: 'v0.4.6',
+    VERSION: 'v0.4.7',
     LANGUAGE: 'None',
     COLLAPSE_INDEX: false,
     FILE_SUFFIX: '.html',

+ 2 - 2
docs/build/html/contributing.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Contributing &mdash; ipfml v0.4.6 documentation</title>
+  <title>Contributing &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -57,7 +57,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/description.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Description &mdash; ipfml v0.4.6 documentation</title>
+  <title>Description &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/examples.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Examples &mdash; ipfml v0.4.6 documentation</title>
+  <title>Examples &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 8 - 13
docs/build/html/genindex.html

@@ -9,7 +9,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Index &mdash; ipfml v0.4.6 documentation</title>
+  <title>Index &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -57,7 +57,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           
@@ -157,8 +157,7 @@
 <h1 id="index">Index</h1>
 
 <div class="genindex-jumpbox">
- <a href="#B"><strong>B</strong></a>
- | <a href="#C"><strong>C</strong></a>
+ <a href="#C"><strong>C</strong></a>
  | <a href="#D"><strong>D</strong></a>
  | <a href="#F"><strong>F</strong></a>
  | <a href="#G"><strong>G</strong></a>
@@ -173,14 +172,6 @@
  | <a href="#W"><strong>W</strong></a>
  
 </div>
-<h2 id="B">B</h2>
-<table style="width: 100%" class="indextable genindextable"><tr>
-  <td style="width: 33%; vertical-align: top;"><ul>
-      <li><a href="ipfml/ipfml.filters.kernels.html#ipfml.filters.kernels.bilateral_diff">bilateral_diff() (in module ipfml.filters.kernels)</a>
-</li>
-  </ul></td>
-</tr></table>
-
 <h2 id="C">C</h2>
 <table style="width: 100%" class="indextable genindextable"><tr>
   <td style="width: 33%; vertical-align: top;"><ul>
@@ -330,10 +321,14 @@
   <td style="width: 33%; vertical-align: top;"><ul>
       <li><a href="ipfml/ipfml.iqa.fr.html#ipfml.iqa.fr.mae">mae() (in module ipfml.iqa.fr)</a>
 </li>
-      <li><a href="ipfml/ipfml.iqa.fr.html#ipfml.iqa.fr.ms_ssim">ms_ssim() (in module ipfml.iqa.fr)</a>
+      <li><a href="ipfml/ipfml.filters.kernels.html#ipfml.filters.kernels.max_bilateral_diff">max_bilateral_diff() (in module ipfml.filters.kernels)</a>
+</li>
+      <li><a href="ipfml/ipfml.filters.kernels.html#ipfml.filters.kernels.min_bilateral_diff">min_bilateral_diff() (in module ipfml.filters.kernels)</a>
 </li>
   </ul></td>
   <td style="width: 33%; vertical-align: top;"><ul>
+      <li><a href="ipfml/ipfml.iqa.fr.html#ipfml.iqa.fr.ms_ssim">ms_ssim() (in module ipfml.iqa.fr)</a>
+</li>
       <li><a href="ipfml/ipfml.iqa.fr.html#ipfml.iqa.fr.mse">mse() (in module ipfml.iqa.fr)</a>
 </li>
       <li><a href="ipfml/ipfml.filters.noise.html#ipfml.filters.noise.mut_white_noise">mut_white_noise() (in module ipfml.filters.noise)</a>

+ 2 - 2
docs/build/html/index.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Image Processing For Machine Learning &mdash; ipfml v0.4.6 documentation</title>
+  <title>Image Processing For Machine Learning &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -57,7 +57,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Documentation &mdash; ipfml v0.4.6 documentation</title>
+  <title>Documentation &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.exceptions.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.exceptions &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.exceptions &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.filters.convolution.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.filters.convolution &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.filters.convolution &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 45 - 19
docs/build/html/ipfml/ipfml.filters.kernels.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.filters.kernels &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.filters.kernels &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           
@@ -179,50 +179,76 @@
 <col width="90%" />
 </colgroup>
 <tbody valign="top">
-<tr class="row-odd"><td><a class="reference internal" href="#ipfml.filters.kernels.bilateral_diff" title="ipfml.filters.kernels.bilateral_diff"><code class="xref py py-obj docutils literal notranslate"><span class="pre">bilateral_diff</span></code></a>(window[,&nbsp;func])</td>
-<td>Bilaeral difference kernel to use with convolution process on image</td>
+<tr class="row-odd"><td><a class="reference internal" href="#ipfml.filters.kernels.max_bilateral_diff" title="ipfml.filters.kernels.max_bilateral_diff"><code class="xref py py-obj docutils literal notranslate"><span class="pre">max_bilateral_diff</span></code></a>(window)</td>
+<td>Bilateral difference kernel to use with convolution process on image</td>
 </tr>
-<tr class="row-even"><td><a class="reference internal" href="#ipfml.filters.kernels.plane_max_error" title="ipfml.filters.kernels.plane_max_error"><code class="xref py py-obj docutils literal notranslate"><span class="pre">plane_max_error</span></code></a>(window)</td>
+<tr class="row-even"><td><a class="reference internal" href="#ipfml.filters.kernels.min_bilateral_diff" title="ipfml.filters.kernels.min_bilateral_diff"><code class="xref py py-obj docutils literal notranslate"><span class="pre">min_bilateral_diff</span></code></a>(window)</td>
+<td>Bilateral difference kernel to use with convolution process on image</td>
+</tr>
+<tr class="row-odd"><td><a class="reference internal" href="#ipfml.filters.kernels.plane_max_error" title="ipfml.filters.kernels.plane_max_error"><code class="xref py py-obj docutils literal notranslate"><span class="pre">plane_max_error</span></code></a>(window)</td>
 <td>Plane max error kernel to use with convolution process on image</td>
 </tr>
-<tr class="row-odd"><td><a class="reference internal" href="#ipfml.filters.kernels.plane_mean" title="ipfml.filters.kernels.plane_mean"><code class="xref py py-obj docutils literal notranslate"><span class="pre">plane_mean</span></code></a>(window)</td>
+<tr class="row-even"><td><a class="reference internal" href="#ipfml.filters.kernels.plane_mean" title="ipfml.filters.kernels.plane_mean"><code class="xref py py-obj docutils literal notranslate"><span class="pre">plane_mean</span></code></a>(window)</td>
 <td>Plane mean kernel to use with convolution process on image</td>
 </tr>
 </tbody>
 </table>
 <dl class="function">
-<dt id="ipfml.filters.kernels.bilateral_diff">
-<code class="descclassname">ipfml.filters.kernels.</code><code class="descname">bilateral_diff</code><span class="sig-paren">(</span><em>window</em>, <em>func=&lt;built-in function max&gt;</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/ipfml/filters/kernels.html#bilateral_diff"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#ipfml.filters.kernels.bilateral_diff" title="Permalink to this definition">¶</a></dt>
+<dt id="ipfml.filters.kernels.max_bilateral_diff">
+<code class="descclassname">ipfml.filters.kernels.</code><code class="descname">max_bilateral_diff</code><span class="sig-paren">(</span><em>window</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/ipfml/filters/kernels.html#max_bilateral_diff"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#ipfml.filters.kernels.max_bilateral_diff" title="Permalink to this definition">¶</a></dt>
 <dd><dl class="docutils">
-<dt>Bilaeral difference kernel to use with convolution process on image</dt>
-<dd>Apply difference pixel to pixel and keep max on min difference before applying mean</dd>
+<dt>Bilateral difference kernel to use with convolution process on image</dt>
+<dd>Apply difference pixel to pixel and keep max difference before applying mean</dd>
 </dl>
 <table class="docutils field-list" frame="void" rules="none">
 <col class="field-name" />
 <col class="field-body" />
 <tbody valign="top">
-<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><ul class="first simple">
-<li><strong>window</strong> – the window part to use from image</li>
-<li><strong>func</strong> – max or min function to get difference between pixels</li>
-</ul>
-</td>
+<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>window</strong> – the window part to use from image</td>
 </tr>
-<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body"><p class="first last">mean of max or min difference of pixels</p>
-</td>
+<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">mean of max difference of pixels</td>
 </tr>
 </tbody>
 </table>
 <p>Example:</p>
-<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="kn">from</span> <span class="nn">ipfml.filters.kernels</span> <span class="k">import</span> <span class="n">bilateral_diff</span>
+<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="kn">from</span> <span class="nn">ipfml.filters.kernels</span> <span class="k">import</span> <span class="n">max_bilateral_diff</span>
 <span class="gp">&gt;&gt;&gt; </span><span class="kn">import</span> <span class="nn">numpy</span> <span class="k">as</span> <span class="nn">np</span>
 <span class="gp">&gt;&gt;&gt; </span><span class="n">window</span> <span class="o">=</span> <span class="n">np</span><span class="o">.</span><span class="n">arange</span><span class="p">(</span><span class="mi">9</span><span class="p">)</span><span class="o">.</span><span class="n">reshape</span><span class="p">([</span><span class="mi">3</span><span class="p">,</span> <span class="mi">3</span><span class="p">])</span>
-<span class="gp">&gt;&gt;&gt; </span><span class="n">result</span> <span class="o">=</span> <span class="n">bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">)</span>
+<span class="gp">&gt;&gt;&gt; </span><span class="n">result</span> <span class="o">=</span> <span class="n">max_bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">)</span>
 <span class="gp">&gt;&gt;&gt; </span><span class="n">result</span>
 <span class="go">3.0</span>
 </pre></div>
 </div>
 </dd></dl>
 
+<dl class="function">
+<dt id="ipfml.filters.kernels.min_bilateral_diff">
+<code class="descclassname">ipfml.filters.kernels.</code><code class="descname">min_bilateral_diff</code><span class="sig-paren">(</span><em>window</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/ipfml/filters/kernels.html#min_bilateral_diff"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#ipfml.filters.kernels.min_bilateral_diff" title="Permalink to this definition">¶</a></dt>
+<dd><dl class="docutils">
+<dt>Bilateral difference kernel to use with convolution process on image</dt>
+<dd>Apply difference pixel to pixel and keep min difference before applying mean</dd>
+</dl>
+<table class="docutils field-list" frame="void" rules="none">
+<col class="field-name" />
+<col class="field-body" />
+<tbody valign="top">
+<tr class="field-odd field"><th class="field-name">Parameters:</th><td class="field-body"><strong>window</strong> – the window part to use from image</td>
+</tr>
+<tr class="field-even field"><th class="field-name">Returns:</th><td class="field-body">mean of min difference of pixels</td>
+</tr>
+</tbody>
+</table>
+<p>Example:</p>
+<div class="highlight-default notranslate"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="kn">from</span> <span class="nn">ipfml.filters.kernels</span> <span class="k">import</span> <span class="n">min_bilateral_diff</span>
+<span class="gp">&gt;&gt;&gt; </span><span class="kn">import</span> <span class="nn">numpy</span> <span class="k">as</span> <span class="nn">np</span>
+<span class="gp">&gt;&gt;&gt; </span><span class="n">window</span> <span class="o">=</span> <span class="n">np</span><span class="o">.</span><span class="n">arange</span><span class="p">(</span><span class="mi">9</span><span class="p">)</span><span class="o">.</span><span class="n">reshape</span><span class="p">([</span><span class="mi">3</span><span class="p">,</span> <span class="mi">3</span><span class="p">])</span>
+<span class="gp">&gt;&gt;&gt; </span><span class="n">result</span> <span class="o">=</span> <span class="n">min_bilateral_diff</span><span class="p">(</span><span class="n">window</span><span class="p">)</span>
+<span class="gp">&gt;&gt;&gt; </span><span class="n">result</span>
+<span class="go">1.0</span>
+</pre></div>
+</div>
+</dd></dl>
+
 <dl class="function">
 <dt id="ipfml.filters.kernels.plane_max_error">
 <code class="descclassname">ipfml.filters.kernels.</code><code class="descname">plane_max_error</code><span class="sig-paren">(</span><em>window</em><span class="sig-paren">)</span><a class="reference internal" href="../_modules/ipfml/filters/kernels.html#plane_max_error"><span class="viewcode-link">[source]</span></a><a class="headerlink" href="#ipfml.filters.kernels.plane_max_error" title="Permalink to this definition">¶</a></dt>

+ 2 - 2
docs/build/html/ipfml/ipfml.filters.noise.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.filters.noise &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.filters.noise &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.iqa.fr.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.iqa.fr &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.iqa.fr &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.metrics.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.metrics &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.metrics &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.processing.compression.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.compression &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.compression &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.processing.movement.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.movement &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.movement &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.processing.reconstruction.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.reconstruction &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.reconstruction &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.processing.segmentation.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.segmentation &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.segmentation &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.processing.transform.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.processing.transform &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.processing.transform &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/ipfml/ipfml.utils.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>ipfml.utils &mdash; ipfml v0.4.6 documentation</title>
+  <title>ipfml.utils &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -58,7 +58,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

BIN
docs/build/html/objects.inv


+ 2 - 2
docs/build/html/py-modindex.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Python Module Index &mdash; ipfml v0.4.6 documentation</title>
+  <title>Python Module Index &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -59,7 +59,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

+ 2 - 2
docs/build/html/search.html

@@ -8,7 +8,7 @@
   
   <meta name="viewport" content="width=device-width, initial-scale=1.0">
   
-  <title>Search &mdash; ipfml v0.4.6 documentation</title>
+  <title>Search &mdash; ipfml v0.4.7 documentation</title>
   
 
   
@@ -56,7 +56,7 @@
             
             
               <div class="version">
-                0.4.6
+                0.4.7
               </div>
             
           

Fichier diff supprimé car celui-ci est trop grand
+ 1 - 1
docs/build/html/searchindex.js


+ 2 - 2
docs/source/conf.py

@@ -24,9 +24,9 @@ copyright = '2019, Jérôme BUISINE'
 author = 'Jérôme BUISINE'
 
 # The short X.Y version
-version = '0.4.6'
+version = '0.4.7'
 # The full version, including alpha/beta/rc tags
-release = 'v0.4.6'
+release = 'v0.4.7'
 
 
 # -- General configuration ---------------------------------------------------

+ 2 - 1
docs/source/ipfml/ipfml.filters.kernels.rst

@@ -9,7 +9,8 @@ ipfml.filters.kernels
 
    .. autosummary::
    
-      bilateral_diff
+      max_bilateral_diff
+      min_bilateral_diff
       plane_max_error
       plane_mean
    

+ 48 - 11
ipfml/filters/kernels.py

@@ -106,8 +106,8 @@ def plane_max_error(window):
     return (errors.max() - errors.min())
 
 
-def bilateral_diff(window, func=max):
-    """Bilaeral difference kernel to use with convolution process on image
+def _bilateral_diff(window, func):
+    """Main bilateral difference kernel to use with convolution process on image
        Apply difference pixel to pixel and keep max on min difference before applying mean
 
     Args:
@@ -116,15 +116,6 @@ def bilateral_diff(window, func=max):
 
     Returns:
         mean of max or min difference of pixels
-
-    Example:
-
-    >>> from ipfml.filters.kernels import bilateral_diff
-    >>> import numpy as np
-    >>> window = np.arange(9).reshape([3, 3])
-    >>> result = bilateral_diff(window)
-    >>> result
-    3.0
     """
 
     window = np.array(window)
@@ -175,3 +166,49 @@ def bilateral_diff(window, func=max):
     col_diff = sum(total_col_diff_list) / len(total_col_diff_list)
 
     return func(row_diff, col_diff)
+
+
+def max_bilateral_diff(window):
+    """Bilateral difference kernel to use with convolution process on image
+       Apply difference pixel to pixel and keep max difference before applying mean
+
+    Args:
+        window: the window part to use from image
+
+    Returns:
+        mean of max difference of pixels
+
+    Example:
+
+    >>> from ipfml.filters.kernels import max_bilateral_diff
+    >>> import numpy as np
+    >>> window = np.arange(9).reshape([3, 3])
+    >>> result = max_bilateral_diff(window)
+    >>> result
+    3.0
+    """
+
+    return _bilateral_diff(window, max)
+
+
+def min_bilateral_diff(window):
+    """Bilateral difference kernel to use with convolution process on image
+       Apply difference pixel to pixel and keep min difference before applying mean
+
+    Args:
+        window: the window part to use from image
+
+    Returns:
+        mean of min difference of pixels
+
+    Example:
+
+    >>> from ipfml.filters.kernels import min_bilateral_diff
+    >>> import numpy as np
+    >>> window = np.arange(9).reshape([3, 3])
+    >>> result = min_bilateral_diff(window)
+    >>> result
+    1.0
+    """
+
+    return _bilateral_diff(window, min)

+ 1 - 1
setup.py

@@ -63,7 +63,7 @@ class BuildTestCommand(setuptools.command.build_py.build_py):
 
 setup(
     name='ipfml',
-    version='0.4.6',
+    version='0.4.7',
     description='Image Processing For Machine Learning',
     long_description=readme(),
     classifiers=[