Borrar filtros
Borrar filtros

sort() in HDL Coder

2 visualizaciones (últimos 30 días)
DN
DN el 28 de Jul. de 2016
Comentada: DN el 26 de Sept. de 2016
Hi, there is no sort() block in HDL Coder, right? I see there is a Simulink sort block in DSP toolbox under Simulink but it falls away in HDL coder library and is not HDL code generation compatible. Has anyone come across having to sort() for HDL coder as I don't want to write it all from scratch? Thanks

Respuestas (2)

Bharath Venkataraman
Bharath Venkataraman el 22 de Sept. de 2016
If you have the Vision HDL Toolbox, it has a Histogram block that is optimized for HDL.
  4 comentarios
DN
DN el 26 de Sept. de 2016
Hmm...I'm not that sure...I was under the impression that first you select your Video format from the drop down list in the Frame To Pixels block (even if you are not interested in video at all the block comes with these settings - you have to specify it in this block). Once the drop down option is selected below it will specify your "Active pixels per line by Active video lines" regardless whether you want it or not. So if I chose say 240p for example, it shows 320 x 240, which is not just any 2-D array as you suggest. I have a 480 x 64 array for example. In Matlab for example this would have just simply been putting a row vector M of size 480 in to histc() specifying it over a range t of size 64, i.e. y = histc(M,t).
I guess what you really mean is you don't need to think in terms of video format you can use any 2-D data set that you want to find a histogram of, but perhaps use a MxN ratio similar to the video format option lines specified by the drop down list of the block "Frame to Pixel Block", then it will work. Let me know if I'm missing your point.
DN
DN el 26 de Sept. de 2016
Actually I saw later on that there is a custom setting, so one would just have to figure out how to adjust the "front porch", and other inputs here for a normal 2D array associated with usual stats and not so image specific.

Iniciar sesión para comentar.


Bharath Venkataraman
Bharath Venkataraman el 31 de Jul. de 2016
There is no support for sort, but it may be useful to know why you would like to implement sort. Is it for a median filter, which is supported?
  3 comentarios
Walter Roberson
Walter Roberson el 31 de Jul. de 2016
You do not need sorted order to select the binning process. You need to know the range of values which you can get with max and min
DN
DN el 2 de Ag. de 2016
Thanks Walter, true I see what you mean.

Iniciar sesión para comentar.

Community Treasure Hunt

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

Start Hunting!

Translated by