how to make visionhdl_​bilatrailf​ilter block parameter spatial and intensity sigma a programmable constant

2 次查看(过去 30 天)
I was trying to make the two sigma parameter spatial and intensity sigma values as a proggramable output. In vision HDL tool box when it was declared as an extra argument in the function call, the following error messsage was shown.
"Failed to compute constant value for nontunable property 'SpatialStdDev'. In code generation, nontunable properties can only be assigned constant values."
Can anyone help me to tune this parameter as a programmable variable?
Thanks in advance.

采纳的回答

Chris Maliepaard
Chris Maliepaard 2021-10-26
Hi Gayathri,
The Bilateral Filter does not support programmable parameters.
There are some potential workarounds you could pursue. You can implement parallel Bilateral Filters and use a Multiport Switch to select the appropriate filter's output at runtime. Alternatively, you could implement a Bilateral Filter using Image Filter blocks which support programmable coefficients.
I hope that helps,
Chris
  2 个评论
Gayathri Sankaran
Gayathri Sankaran 2021-10-26
Thank you for the response Chris.
Can you share some more details about implementing bilateral filter functionality using imfiler block?
thanks in advance
Chris Maliepaard
Chris Maliepaard 2021-10-27
Hi Gayathri,
The bilateral filter can be described as a Gaussian filter in the spatial dimension that modifies the coefficients of a second Gaussian filter that operates on intensity.
The documentation for the Bilateral Filter provides a section on its algorithm, you would need to implement a coefficient calculation system similar to that shown in the dashed region of the algorithm documentation and pass this to the coeff input port of an Image Filter.
Kind regards,
Chris

请先登录,再进行评论。

更多回答(0 个)

标签

产品


版本

R2021b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by