Optimized Bayesian Nonlocal Means With Block OBNLM
Optimized bayesian nonlocal-means algorithm for denoising ultrasound image
Install / Use
npx skills add Xingorno/Optimized-Bayesian-Nonlocal-means-with-block-OBNLMInstalls into whichever agent you are using.
README
Optimized-Bayesian-Nonlocal-means-with-block(OBNLM)
Optimized bayesian nonlocal-means algorithm for denoising ultrasound image
Description
- BayesianNLM.m : the OBNLM algorithm
- getPearsonDistance.m: compute the pearson distance based bayesian framework
- ImgNormalize.m: pre-processing the image (histogram stretching)
- testBayesianNLM.m: test our algorithm using the input (noisyImage.png) and get the output (despeckledImage.png)
Reference Paper
Coupé, Pierrick, et al. "Nonlocal means-based speckle filtering for ultrasound images." IEEE transactions on image processing 18.10 (2009): 2221-2229.
Basic Principle
The blockwise Nonlocal Means algorithm is completed. The basic principle is shown below:

Object Function: <img src="http://latex.codecogs.com/svg.latex?NL(u)(B_j) = \sum_{i\in\Delta_j}w(B_i,B_j)u(Bi)" border="0"/> with <img src="http://latex.codecogs.com/svg.latex? w(B_i,B_j)=\frac{1}{Z^j}e^{-\frac{dp(u(B_i),u(B_j))}{h^2}}" border="0"/>
<p align="center"><img src="http://latex.codecogs.com/svg.latex? B" border="0"></p>: the blockwise of image<img src="http://latex.codecogs.com/svg.latex? dp(u(B_i),u(B_j))" border="0"/>:the pearson distance between blockwise
Results
The original ultrasound image (with speckle) vs the despeckled ultrasound image:
<p align="center"> <img src="noisyImage.png" border="0" height = "380" width="400"/> <img src="despeckledImage.png" border="0" height="380" width="400"/> </p>Related Skills
node-connect
385.5kDiagnose OpenClaw Android, iOS, or macOS node pairing, QR/setup code, route, auth, and connection failures.
blender-python-addon
40.5kBlender Python add-on rules for operators, panels, properties, registration, testing, and API-safe scripting
flutter-development-guidelines-cursorrules-prompt-file
40.5kCursor rules for Flutter development with MVVM architecture, Riverpod state management, Material widgets, and Dart style guidelines.
commit-push-pr
140.6kCommit, push, and open a PR
Languages
Security Score
Audited on Oct 20, 2025
