]> AND Private Git Repository - book_gpu.git/blobdiff - BookGPU/Chapters/chapter3/code/medianGeneric.cu
Logo AND Algorithmique Numérique Distribuée

Private GIT Repository
modif
[book_gpu.git] / BookGPU / Chapters / chapter3 / code / medianGeneric.cu
index bf418424274c290615fff244069fb49ea51ed9b9..dff2a922ba3dcdae5ec5a85fa34d67ce23759359 100755 (executable)
@@ -18,7 +18,7 @@ __global__ void kernel_medianR( short *output,
   for(ic=0; ic<256; ic++)
        {
          cpt += histogram[ ic ] ;
   for(ic=0; ic<256; ic++)
        {
          cpt += histogram[ ic ] ;
-         // selection of 50% percentil
+         // selection of the median valu
          if ( cpt > ((2*r+1)*(2*r+1))>>1 ) break ; 
        } 
   output[ __mul24(i, j_dim) +j ] =  ic ;  
          if ( cpt > ((2*r+1)*(2*r+1))>>1 ) break ; 
        } 
   output[ __mul24(i, j_dim) +j ] =  ic ;