<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:sy="http://purl.org/rss/1.0/modules/syndication/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/">
<channel>
<title>DMMD</title>
<atom:link href="http://dmmd.net/main_wp/feed/" rel="self" type="application/rss+xml" />
<link>http://dmmd.net/main_wp</link>
<description>Digital Multi-Media Design Web Page</description>
<lastBuildDate>Thu, 10 May 2012 11:06:57 +0000</lastBuildDate>
<language>en</language>
<sy:updatePeriod>hourly</sy:updatePeriod>
<sy:updateFrequency>1</sy:updateFrequency>
<generator>http://wordpress.org/?v=3.3.2</generator>
<item>
<title>Photoshop Host SDK</title>
<link>http://dmmd.net/main_wp/software-development/photoshop-host-sdk/</link>
<comments>http://dmmd.net/main_wp/software-development/photoshop-host-sdk/#comments</comments>
<pubDate>Mon, 19 Mar 2012 11:36:42 +0000</pubDate>
<dc:creator>admin</dc:creator>
<category>
<![CDATA[Software Development]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1530</guid>
<description>
<![CDATA[At DMMD we have developed a Photoshop Host SDK that will allow you to run any Photoshop Plugin without the use of Photoshop. This can be a very powerful tool that allows you to integrate existing Photshop Filters into your own application, without the need of Photoshop. In theory, we can even use DMMD&#8217;s Phothsop [...]]]>
</description>
<content:encoded>
<![CDATA[<p>At DMMD we have developed a <a href="http://dmmd.net/main_wp/photoshop/">Photoshop Host SDK</a> that will allow you to run any Photoshop Plugin without the use of Photoshop.  This can be a very powerful tool that allows you to integrate existing Photshop Filters into your own application, without the need of Photoshop.  In theory, we can even use DMMD&#8217;s Phothsop Host on Linux! &#8212; however, there are no Linux Photoshop Plugins!  (If you would like to port your own plugin on Linux, please contact us and we can discuss.)</p>
<p>OK, so how do you use the SDK?  Well, it&#8217;s very simple, just follow these steps:</p>
<p>1. Download the SDK.<br />
2. From the DOS prompt, go to the &#8220;vsrPp_sdk\bin\Win32&#8243; directory.<br />
3. Copy your Photoshop Plugin to the &#8220;vsrPp_sdk\bin\Win32\Photoshop&#8221; directory.<br />
4. Run the command:  vsrPp_app.exe &#8220;myFileName.jpg&#8221; &#8212; please note that the exe supports only JPG files.<br />
5. If you like what you see and you want to incorporate the SDK into your own application, take a look at the files:</p>
<ol>
<li>vsrPp_sdk\example\vsrPp_app.cpp </li>
<li>vsrPp_sdk\include\vsrPp_sdk.h </li>
</ol>
<p>That&#8217;s about it!  Take a look at how the SDK is being used in the example application and then use it in the same fashion in your own application.  If you&#8217;re all set, then Enjoy!  If you need further help, please do not hesitate to contact our team at contact@dmmd.net.</p>
<p>Best,<br />
The DMMD Development Team</p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/software-development/photoshop-host-sdk/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>Visere Medical Processing Pipeline</title>
<link>http://dmmd.net/main_wp/visere-medical/visere-medical-algorithms/</link>
<comments>http://dmmd.net/main_wp/visere-medical/visere-medical-algorithms/#comments</comments>
<pubDate>Thu, 08 Dec 2011 01:20:56 +0000</pubDate>
<dc:creator>admin</dc:creator>
<category>
<![CDATA[Visere Medical Viewer]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1433</guid>
<description>
<![CDATA[Visere Medical provides several different algorithms for enhancing medical XRay images.  I will discuss several of the filters available to Visere Medical and what their effect is on the output of the final image.  You can evaluate these algorithms with your own images by downloading a copy of our Visere Medical Viewer software or you [...]]]>
</description>
<content:encoded>
<![CDATA[<p>Visere Medical provides several different algorithms for enhancing medical XRay images.  I will discuss several of the filters available to Visere Medical and what their effect is on the output of the final image.  You can evaluate these algorithms with your own images by downloading a copy of our <a href="http://dmmd.net/main_wp/visere-medical/" title="VisereMedicalViewer">Visere Medical Viewer</a> software or you can download a copy of our <a href="http://dmmd.net/main_wp/visere-6-5/" title="MedicalPhotoshopPlugin">Medical Photoshop Plugin</a>.  The discussion in this blog assumes that you are using our free <a href="http://dmmd.net/main_wp/visere-medical/" title="VisereMedicalViewer">Visere Medical Viewer</a>.</p>
<p>To access all the filters available within the Visere Medical application (also called WhiteCap Viewer) you need to enable the Process Toolbar.  This is done by clicking on the Process menu item.  The Process toolbar starts off un-docked and it can be moved around or docked by simply dragging it to the desired location.  Once the Process toolbar is visible, the list of available processes can be accessed by clicking the down arrow in the upper left corner of the toolbar.  Of all the available filters, a few of them are discussed next.</p>
<p><strong>Processing Pipeline</strong></p>
<p>The most versatile filter is the Pipeline Filter.  The Pipeline filter has the ability to create new filters by stringing together a list of existing base filters.  The pipeline filter can be used to define different pipelines, which can use different lists of filters, or the same list of filters but with different settings for each of the individual filters.  </p>
<p>For example, when processing XRay films of a large dog and a small cat, different filter settings need to be used for the two different animals.  For the large dog an increased level of contrast might be necessary, whereas for the cat, a lower contrast level might be more appropriate.  To see how to configure and use the Pipeline filter we&#8217;ll look at an example. We want to compare two images, one processed with DMMD&#8217;s algorithms and one processed with a 3rd party algorithm.  The steps are as follow:</p>
<ol>  </p>
<li> Open up the two images <a href="http://dmmd.net/main_wp/visere-image-viewer/medical-image-comparison/" title="side-by-side">side by side</a>, with the unprocessed image on the left and the 3rd party processed image on the right.  From the Process window select Edit Pipeline.
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-1208-02-57-678-1024x640.jpg" alt="" title="VisereCapture[2011-12-12][08-02-57-678]" width="1024" height="640" class="aligncenter size-large wp-image-1497" />
</li>
<li> A dialog similar to the image shown below will pop-up.  Press the New button and a new entry titled Pipeline Name will appear.  Double click on the cell with the Pipeline Name and enter the name of the new pipeline.  In our example, the name used for this pipeline is Genesis.  Up to 20 processes can be stringed together to generate a new pipeline called Genesis.
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-0806-25-09-712.jpeg" alt="" title="VisereCapture[2011-12-08][06-25-09-712]" width="858" height="409" class="aligncenter size-full wp-image-1476" /></li>
<li> Each of the individual filters can be edited by clicking on the three points button [...] and the individual configuration dialog will open as shown.  In the image below, the example of Adaptive Histogram Equalization configuration is shown.
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-1208-03-05-743-1024x640.jpg" alt="" title="VisereCapture[2011-12-12][08-03-05-743]" width="1024" height="640" class="aligncenter size-large wp-image-1499" /></li>
<li> After all the filters are selected and configured, click OK to save the pipeline.  In the process list, the new pipeline will now be listed, just above the Edit Pipeline filter.  In this case, the new entry is Genesis.
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-1208-03-11-780-1024x640.jpg" alt="" title="VisereCapture[2011-12-12][08-03-11-780]" width="1024" height="640" class="aligncenter size-large wp-image-1500" /></li>
<li> Select the new process &#8212; Genesis.  When the process is selected a list of all the different filters that are part of the new process is shown.  This allows you to confirm that the pipeline is indeed properly defined.  The pipeline can be edited at any time by going back to Edit Pipeline.
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-1208-03-15-805-1024x640.jpg" alt="" title="VisereCapture[2011-12-12][08-03-15-805]" width="1024" height="640" class="aligncenter size-large wp-image-1501" /></li>
<li> Make sure that the active window is the window on the left (the raw image) and then hit the Apply button at the bottom of the filter.  The process is then applied to the left side image and the results are shown once the process is complete.
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-1208-03-24-978-1024x640.jpg" alt="" title="VisereCapture[2011-12-12][08-03-24-978]" width="1024" height="640" class="aligncenter size-large wp-image-1502" /></li>
</ol>
<p>For processing XRays, there are a multitude of options, but some processes are more useful than others.</p>
<p><strong>Median And XRay Denoise Processes</strong></p>
<p>The median filter is good for salt and pepper noise, as we&#8217;ve discussed it <a href="http://dmmd.net/main_wp/research/denoising/">here</a>.  In the current implementation we only process windows of sizes 3&#215;3.  This is intentionally enforced for reasons of speed and because larger windows can create too much of an edge shift in the final images.  Since we are interested in only removing the strongest noise, the default of 3&#215;3 seems to be good.</p>
<p>XRay Denoise is a more advanced version of the median filter.  Unlike the median filter, this filter analyzes each pixel in the image and modifies it only if the algorithm considers it a noisy pixel.  This tends to minimize the amount of correction and most importantly, eliminates the edge shift, usually introduced by median filtering.  The filter is mostly recommended for sensors that have a few bad pixels.</p>
<p><strong>AQua Denoise</strong></p>
<p>This filter removes White Gaussian noise, as discussed <a href="http://dmmd.net/main_wp/research/denoising/">here</a>.  Do not use a windows size larger than 3, otherwise the filter will be VERY slow.  This is a problem in the current implementation of the filter.  In the future we will optimize the filter for larger window sizes as well.  Thus, leave the window size at 3.  The first parameter, Sigma, is the level of noise.  Use a noise level of at most 15.  Using anything higher than 15 tends to denoise the image too much and since the image denoises local patches, too much denoising manifests itself by introducing &#8220;blocky&#8221; regions in locations where there might be less noise.</p>
<p><strong>Adaptive Histogram Equalization</strong></p>
<p>This filter is DMMD&#8217;s most effective filter for enhancing image contrast.<br />
Histogram equalization is a well known technique for enhancing contrast over an entire image and we have discussed it<br />
<a href="http://dmmd.net/main_wp/intuitive-mathematics/histogram-equalization/">here</a>.</p>
<p>This filter is the adaptive version of histogram equalization.  The parameters required by this filter are as follows:</p>
<ol>
<li> <i>Window and Border Size</i>:  The overall image is broken up in regions that are Window Size large and histogram equalization is applied to each region independently.  Since the regions are independent, this can potentially introduce border artifacts.  To minimize these border artifacts, the Border Size controls the amount of overlap between neighboring patches.  Thus, the histogram equalization patch size is Window Size plus Border Size, with Border Size overlap.</li>
<li><i>Distribution Type</i>: In the <a href="http://dmmd.net/main_wp/intuitive-mathematics/histogram-equalization/">Histogram Equalization</a> blog we discussed how the re-mapping of the pixel values can be done such that their distribution (or the cumulative distribution function) can look like any desired distribution.  Currently, the algorithm has three different distribution types.  Experimentation with each distribution type is highly encouraged!  The performance of the filter can vary significantly from one distribution type to another.</li>
<li> <i>Distribution Constant</i>: this is a constant value used for controlling the distribution spread.  For Exponential and Rayleigh distributions it corresponds to the standard distribution.  For the Uniform distribution it has no effect.</li>
<li><i>Clip Limit</i>:  This variable (between 0 and 1) controls the amount of histogram equalization that is to be applied to each patch.  A value of zero means no histogram equalization.</li>
</ol>
<p><strong>Unsharp Masking</strong></p>
<p>Unsharp masking boosts the high frequencies in an image by a factor proportional to the Gain.  The high frequency in the image is obtained by subtracting from the image a low frequency version of it. The low frequency image is obtained by convolving the original image with a Gaussian of radius R. Thus R is the radius of the Gaussian and Gain is a multiplicative factor that enhances the high frequencies.  Higher Gain implies enhanced edges &#8212; and noise, since noise is high frequency.</p>
<p>&#8211; Darian Muresan</p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/visere-medical/visere-medical-algorithms/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>Side By Side Image Comparison</title>
<link>http://dmmd.net/main_wp/visere-image-viewer/medical-image-comparison/</link>
<comments>http://dmmd.net/main_wp/visere-image-viewer/medical-image-comparison/#comments</comments>
<pubDate>Wed, 07 Dec 2011 21:48:30 +0000</pubDate>
<dc:creator>admin</dc:creator>
<category>
<![CDATA[Visere Image Viewer]]>
</category>
<category>
<![CDATA[Visere Medical Viewer]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1447</guid>
<description>
<![CDATA[Visere and Visere Medical provide side by side image comparison to allow you to easily evaluate and compare two separate images. The side by side comparison works best when two images are of the same size. To enable side-by-side comparison, take the following two steps, as shown in the Figure above: First, enable two side [...]]]>
</description>
<content:encoded>
<![CDATA[<p>Visere and Visere Medical provide side by side image comparison to allow you to easily evaluate and compare two separate images.  The side by side comparison works best when two images are of the same size.  </p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-0722-13-01-544-1024x640.jpg" alt="" title="VisereCapture[2011-12-07][22-13-01-544]" width="1024" height="640" class="aligncenter size-large wp-image-1458" /></p>
<p>To enable side-by-side comparison, take the following two steps, as shown in the Figure above:</p>
<ol>
<li>First, enable two side viewing from the menu: View->Two Split View (Ctrl+V)</li>
<li>Second, enable zoom-lock from the menu: View->Zoom->Lock Zoom &#038; Scroll (Ctrl+L).  This will force whatever zooming and scrolling you do in one window to be applied to the other window.  The active window has a red border around it.</li>
</ol>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-0722-17-30-257-300x187.jpg" alt="" title="VisereCapture[2011-12-07][22-17-30-257]" width="300" height="187" class="alignleft size-medium wp-image-1463" /></p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/12/VisereCapture2011-12-0722-17-25-189-300x187.jpg" alt="" title="VisereCapture[2011-12-07][22-17-25-189]" width="300" height="187" class="alignleft size-medium wp-image-1464" /></p>
<p>To test the new setting, scroll and zoom in the active image.  You will notice that the other image scrolls and zooms the same way.  The images are tied together at the origin.  This means that if the two images are not the same size, then the second image will zoom and scroll in such a way that it&#8217;s origin, the upper-left corner of the image, remains locked to the origin of the first image.  An example of locked zoom and scroll is shown in the two images on the left.</p>
<p>The red border (barely visible) is on the left-side image.  This means that the left-side image is the active image.  Any zoom-scroll is applied to the active image first and then to the right-side image.  Scroll and zoom into the left image.  The right image view will follow around the left image view.</p>
<p>(Also note: all image processes used are applied only to the active image, the image with the red border around it.)</p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/visere-image-viewer/medical-image-comparison/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>DMA Design Manual</title>
<link>http://dmmd.net/main_wp/dmmd-algorithms-dma/dma-design-manual/</link>
<comments>http://dmmd.net/main_wp/dmmd-algorithms-dma/dma-design-manual/#comments</comments>
<pubDate>Sun, 04 Dec 2011 03:34:54 +0000</pubDate>
<dc:creator>admin</dc:creator>
<category>
<![CDATA[DMMD Algorithms (DMA)]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1426</guid>
<description>
<![CDATA[In trying to come up with better methods of organizing and presenting concepts related to DMMD&#8217;s Algorithms Library, nothing seems to work better than presenting all the design ideas in a PDF manual. The latest PDF manual (generated with LaTeX) is available for download here. Certain chapters from the manual will also be presented in [...]]]>
</description>
<content:encoded>
<![CDATA[<p>In trying to come up with better methods of organizing and presenting concepts related to DMMD&#8217;s Algorithms Library, nothing seems to work better than presenting all the design ideas in a PDF manual.  The latest PDF manual (generated with LaTeX) is available for download <a href="http://pictomic.com/AutoDocumentation/Algorithms/main/" title="here">here</a>.</p>
<p>Certain chapters from the manual will also be presented in these blog pages.</p>
<p>&#8211; Darian Muresan </p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/dmmd-algorithms-dma/dma-design-manual/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>Software Development PDF Manual</title>
<link>http://dmmd.net/main_wp/software-development/software-development-pdf-manual/</link>
<comments>http://dmmd.net/main_wp/software-development/software-development-pdf-manual/#comments</comments>
<pubDate>Sun, 04 Dec 2011 03:31:59 +0000</pubDate>
<dc:creator>admin</dc:creator>
<category>
<![CDATA[Software Development]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1423</guid>
<description>
<![CDATA[In trying to come up with better methods of organizing and presenting concepts related to DMMD&#8217;s Software Development practices, I am compiling a manual with all of the different ideas. The latest PDF manual (generated with LaTeX) will always be available for download here. Certain chapters from the manual will also be presented in these [...]]]>
</description>
<content:encoded>
<![CDATA[<p>In trying to come up with better methods of organizing and presenting concepts related to DMMD&#8217;s Software Development practices, I am compiling a manual with all of the different ideas.  The latest PDF manual (generated with LaTeX) will always be available for download <a href="http://pictomic.com/AutoDocumentation/SoftwareDevelopment/main" title="here">here</a>.</p>
<p>Certain chapters from the manual will also be presented in these blog pages.</p>
<p>&#8211; Darian Muresan </p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/software-development/software-development-pdf-manual/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>Intuitive Mathematics PDF Manual</title>
<link>http://dmmd.net/main_wp/intuitive-mathematics/intuitive-mathematics-pdf-manual/</link>
<comments>http://dmmd.net/main_wp/intuitive-mathematics/intuitive-mathematics-pdf-manual/#comments</comments>
<pubDate>Sun, 04 Dec 2011 01:00:09 +0000</pubDate>
<dc:creator>admin</dc:creator>
<category>
<![CDATA[Intuitive Mathematics]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1419</guid>
<description>
<![CDATA[In trying to come up with better methods of organizing and presenting concepts related to Intuitive Mathematics, nothing seems to work better than using LaTeX. Therefore, the latest PDF manual (generated with LaTeX) will always be available for download here. Certain chapters from the Intuitive Mathematics manual will also be presented in these blog pages. [...]]]>
</description>
<content:encoded>
<![CDATA[<p>In trying to come up with better methods of organizing and presenting concepts related to Intuitive Mathematics, nothing seems to work better than using LaTeX.  Therefore, the latest PDF manual (generated with LaTeX) will always be available for download <a href="http://pictomic.com/AutoDocumentation/IntuitiveMathematics/main" title="here">here</a>.</p>
<p>Certain chapters from the Intuitive Mathematics manual will also be presented in these blog pages.</p>
<p>&#8211; Darian Muresan </p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/intuitive-mathematics/intuitive-mathematics-pdf-manual/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>Software Branching</title>
<link>http://dmmd.net/main_wp/software-development/software-branching/</link>
<comments>http://dmmd.net/main_wp/software-development/software-branching/#comments</comments>
<pubDate>Sat, 09 Jul 2011 18:52:13 +0000</pubDate>
<dc:creator>darian</dc:creator>
<category>
<![CDATA[Software Development]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1376</guid>
<description>
<![CDATA[Software branching is an important sub-process of the overall software development process. The practice that we follow at DMMD is shown in the following figure. In the above figure, time progresses from left to right and it is recorded using a changelist. A changelist is a number that increases each time a new submission to [...]]]>
</description>
<content:encoded>
<![CDATA[<p>Software branching is an important sub-process of the overall software development process.  The practice that we follow at DMMD is shown in the following figure.</p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/07/SoftwareBranching1.png" alt="" title="SoftwareBranching" width="833" height="595" class="aligncenter size-full wp-image-1383" /></p>
<p>In the above figure, time progresses from left to right and it is recorded using a changelist.  A changelist is a number that increases each time a new submission to the software repository is made.  Thus, a repository submission with a changelist of 12023 means that it was made before a repository submission of changelist 12050.  The branching methodology then follows these rules:</p>
<p><strong>The Main Branch</strong>.  The main branch, shown in black, is considered the golden standard.  It is the branch from which all of the release branches are made and into which all the experimental branches are integrated.  The main branch is a single branch.  The main brunch is sometimes called the trunk, as in the trunk of a tree with branches.</p>
<p><strong>The Release Branch</strong>.  The release branch always starts off the main branch.  A release branch starts off with a MAJOR release.  Once a major release is done, no new features are added to the release branch.  All new features are added only to the main or experimental branches.  The release branch has a finite lifetime and it is extended only when a bug is fixed in the released version.  When a bug is found in the release branch, the bug is fixed in the release branch first (changelist 12023) and then it is integrated into the main branch (changelist 12050).  If new releases have been made, before the bug fix is integrated into the main branch (changelist 12050), then the bug fix is integrated into all the release branches (changelist 12051) that have been made before the integration of the bug fix (changelist 12050).  The key is that all bug fixes are immediately integrated into the main branch and from the main branch they are integrated into all the other branches.</p>
<p><strong>The Experimental Branch</strong>.  The experimental branch is used when new features are tried, or when code experiments are made.  The experimental branch must always be eventually integrated back into the main branch.  An experimental branch cannot take a life of its own, independent of the main branch.</p>
<p>Branching when a project contains several different components, is a bit more complex and will be discussed in the next entry.</p>
<p>&#8211; Darian Muresan</p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/software-development/software-branching/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>Histogram Equalization</title>
<link>http://dmmd.net/main_wp/intuitive-mathematics/histogram-equalization/</link>
<comments>http://dmmd.net/main_wp/intuitive-mathematics/histogram-equalization/#comments</comments>
<pubDate>Mon, 27 Jun 2011 13:34:14 +0000</pubDate>
<dc:creator>darian</dc:creator>
<category>
<![CDATA[Intuitive Mathematics]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1335</guid>
<description>
<![CDATA[What exactly is histogram equalization and how can we think of it from an intuitive point of view, rather than the more abstract, mathematical point of view? A somewhat detailed technical point of view is given on the Wiki Page. Still, I believe there are some mathematical concepts, which I believe can be explained more [...]]]>
</description>
<content:encoded>
<![CDATA[<p>What exactly is histogram equalization and how can we think of it from an intuitive point of view, rather than the more abstract, mathematical point of view?  A somewhat detailed technical point of view is given on the <a href="http://en.wikipedia.org/wiki/Histogram_equalization">Wiki Page</a>.  Still, I believe there are some mathematical concepts, which I believe can be explained more intuitively.  Here&#8217;s my take on histogram equalization.</p>
<p>Without being too rigorous about the mathematical details and the distinction between discrete and continuous cases, let’s understand how histogram equalization is implemented.  </p>
<p>First, what exactly is histogram equalization?  Ideally, histogram equalization would spread the pixel values uniformly across an entire image.  Thus, if we had an image with 256 pixels in it, then 1 pixel would have value 0, 1 pixel would have a value of 1, &#8230;, and one pixel would have a value of 255.  If the image had 1024 total pixels, then the normalized image would have 4 pixels of value 0, 4 pixels of value 1, &#8230;, and 4 pixels of value 255.  However, knowing how to spread the pixel values around an image, such that we have a uniform distribution as described above, can be tricky.  Instead, what histogram equalization does (in the discrete case) is that it spreads and adjusts the level of the pixel values (as a group) in the histogram such that the cumulative area under the new histogram (moving from left to right) increases linearly.  </p>
<p>A simple example might be in order.  Assume that image I contains 6 pixels: two of value 10, two of value 20 and two of value 199.  Further, assume that each pixel can be represented using 8 bits (i.e. minimum value is 0 and maximum is 255).  Then the histogram equalized image would have two pixels of value 0, two pixels of value 128 and two pixels of value 255.  </p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/06/histogram.jpg" alt="" title="histogram" width="799" height="388" class="aligncenter size-full wp-image-1341" /></p>
<p>Second, let&#8217;s understand histogram equalization in more details.  The Figure above shows the histogram of some image I.  The histogram is a distribution function that tells how many pixels are at a certain pixel value. The x − axis is the pixel value, such as pixel value i, and the y − axis is the count, or the number of pixels of value i. Histograms are not 1-to-1 with the image. For example, two different images, I and J can have the same histogram if the locations of the pixels in I are permutations of the pixel locations in J.</p>
<p>The cumulative distribution function (cdf) is the cumulative area under the histogram curve. In the continuous case, this area is an integral and in the discrete case, it is a sum.  The cdf(i) is calculated as the area under the histogram curve, up to pixel i.  </p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/06/cdf.jpg" alt="" title="cdf" width="799" height="877" class="aligncenter size-full wp-image-1343" /></p>
<p>In the figure above, the cdf(i) is the red line in the bottom graph.  (Notice that the line is monotonically increasing, since the area under the histrogram curve can only increase as we move from left to right.  Also note, that the red line is an approximation of the cdf.)  The top graph shows the histogram of image I.  At step i (pixel value i) the cdf function increases by the sum Si.</p>
<p>In the following figure, the green line represents the cumulative distribution function for the normalized histogram, call it cdf_norm (shown in the figure as having a bar on top).  The cdf_norm is a straight line because the integral of a constant function is a straight line and it has a slope of 1 because both axis have been normalized to [0, 1].  </p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/06/normalize.jpg" alt="" title="normalize" width="799" height="561" class="aligncenter size-full wp-image-1344" /></p>
<p>In order to convert cdf into cdf_norm, the sum contribution, which is Si along the y-axis, needs to be made at exactly the same time as when the step Si is taken along the x-axis (i.e. when we are adding the contribution of pixel Si).  If this is true for all steps before step i, then step i needs to be moved to cdf(i).  This is achieved by simply assigning all the pixels that were of value i to be of value cdf(i).  Note that the number of pixels that were of value i is the SAME as the number of pixels that are now of value cfd(i).  The sum Si, the contribution to the y-axis, does not change when the pixels of value i are changed to cdf(i).</p>
<p>Finally, if the desire is to convert cdf(i) to some new cumulative distribution function, call it cdf_new(i) (shown as cdf with a hat in the figure below) then this can be achieved by re-assigning i to the inverse of cdf_new of cdf(i).  This mapping is shown in the figure below.  </p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/06/toAnyHistogram.jpg" alt="" title="toAnyHistogram" width="799" height="561" class="aligncenter size-full wp-image-1345" /></p>
<p>The figures above try to capture and explain the logic behind histogram equalization and histogram re-mapping.  The DMA Manual has a more detailed mathematical explanation (in the chapter titled dmaHistogramEqualization).</p>
<p>&#8211; Darian Muresan</p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/intuitive-mathematics/histogram-equalization/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>Software, Hardware and Firmware</title>
<link>http://dmmd.net/main_wp/software-development/software-hardware-and-firmware/</link>
<comments>http://dmmd.net/main_wp/software-development/software-hardware-and-firmware/#comments</comments>
<pubDate>Wed, 15 Jun 2011 11:57:53 +0000</pubDate>
<dc:creator>darian</dc:creator>
<category>
<![CDATA[Software Development]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1260</guid>
<description>
<![CDATA[In understanding the complexities of software development, let’s pause for a second and ask the question: What is software? The American Heritage Dictionary defines software as:  written or printed data such as programs, routines, and symbolic languages, essential to the operation of computers. This definition is mostly correct, but I would go a step further [...]]]>
</description>
<content:encoded>
<![CDATA[<p>In understanding the complexities of software development, let’s pause for a second and ask the question:</p>
<p><em>What is software? </em></p>
<p>The American Heritage Dictionary defines software as:  written or printed data such as programs, routines, and symbolic languages, essential to the operation of computers.</p>
<p>This definition is mostly correct, but I would go a step further and say that software is anything that controls hardware. Software does not exist solely inside computers. Instead, software controls parts of your car, phone, toaster, oven, coffee maker, and just about any piece of electronic hardware you have in your home or workplace.  A more complete definition of software would be:</p>
<p><em>Software is a set of hardware instructions and their representation, which we call programs.</em></p>
<p>Programs can be represented on punch cards, magnetic tapes, film, and other media. It is important to understand that software is a set of instruction, not the physical media on which it is recorded. Hardware, in contrast I would define it as:</p>
<p><em>Electronic hardware is anything that is electrical or current goes through.</em></p>
<p>Hardware consists of tangible objects such as: electronic circuits, input/output devices, cables and the likes and it does not consist of abstract ideas, algorithms or instructions.  An intermediate form between hardware and software is called firmware and this is defined as:</p>
<p><em>Firmware is software embedded in hardware.</em></p>
<p>There is not much of a difference between software and firmware and in fact one could easily argue that they are equivalent.  Firmware tends to be embedded into the hardware at manufacturing time and it is not expected to change for the lifetime of the hardware device. In addition, firmware is not lost when hardware looses power, whereas software, in the traditional sense, does not remain in memory when the hardware loses power.</p>
<p>If there is one key idea to consider about software, is that unlike other engineering projects, a software project tends to be more of a living project. A software project is much more like a plant that needs continuous watering in order to remain relevant.  Because of the fast moving pace of computer hardware new versions of the same software, with new features, need to be developed and these new versions are most often built on top of previous versions.  Contrast this with building a bridge, where once a bridge is built, it is good for many years, without major maintenance.</p>
<p>Understanding this key difference between a software project and most other engineering projects is important in order to appreciate the difficulty of building good software, as it will be highlighted in future chapters. Finally, a more thorough discussion of hardware and software definitions can be found in [1].</p>
<p><strong>Hardware &#8211; Software Interaction</strong></p>
<p>In most cases hardware and software are logically equivalent, in the sense that most algorithms can be implemented in either hardware or software and the decision which way to implement is solely up to the designer. In general, hardware tends to be extremely fast and can perform only a limited number of instructions, such as:</p>
<ol>
<li>Additions</li>
<li>Comparisons</li>
<li>Moves and Copies</li>
</ol>
<p>The software uses these basic instructions to create complex algorithms. The software that directly controls hardware is called machine language. Because most machine languages are so simple, a lot of instructions are required to create even the simplest of algorithms. This can in turn become very tedious and laborious. Therefore software to generate this machine language was developed. This process of different software levels of development is highlighted in the following Figure [1]:</p>
<p><center><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/06/MultiLevelMachines.png"></center></p>
<p>Levels 1, 2, and 3 are numeric.  Programs in these levels consist of a series of numbers, which are hard for people to interpret. Level 4 is the assembly language, which becomes a bit more user friendly. At this level the instructions contain words and abbreviations meaningful to people. Level 5 and higher is what most people think of when they think of software development. At this level you have the standard programming languages, such as C, C++, FORTRAN, etc. At levels higher than 5 you have virtual languages, such as .NET and Java. For comparison purposes, here is an example of an assembly language program (Level 4) and the equivalent C (Level 5).</p>
<p><img src = http://dmmd.net/main_wp/wp-content/uploads/2011/06/assembly.png></p>
<p>The same program written in C would look approximately like this:<br />
<img src = http://dmmd.net/main_wp/wp-content/uploads/2011/06/c.png></p>
<p>Notice how much more readable the program in C (Level 5) looks like when compared to assembly.  The logic level is when you get down to the transistor level.</p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/06/LogicLevel-1024x510.png" alt="" title="LogicLevel" width="1024" height="510" class="aligncenter size-large wp-image-1317" /></p>
<p>From left to right, we have a transistor (acting like an inverter), a NAND logic (high, high outputs low) and a NOR logic (either high produces a low).  The resistors, the wiggly lines, are there to limit the current across the transistor&#8217;s gates, so that the transistors don&#8217;t burn.  Interestingly enough, a transistor is used for power amplifiers as well.  The difference is that in a power-amplifier, the transistor has to be biased such that it works in the transition region, whereas in the digital world, the transistor works in the saturated regions (high or low).  More discussions on the transistor will be in another blog entry. </p>
<p>&#8211; D. Darian Muresan</p>
<p><strong>Bibliography</strong></p>
<p>[1] A. S. Tanenbaum, Structured Computer Organization. Prentice Hall, 1990.</p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/software-development/software-hardware-and-firmware/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
<item>
<title>Principal Components and Spin Images</title>
<link>http://dmmd.net/main_wp/intuitive-mathematics/principal-components-and-spin-images/</link>
<comments>http://dmmd.net/main_wp/intuitive-mathematics/principal-components-and-spin-images/#comments</comments>
<pubDate>Tue, 12 Apr 2011 13:44:05 +0000</pubDate>
<dc:creator>darian</dc:creator>
<category>
<![CDATA[Intuitive Mathematics]]>
</category>
<guid isPermaLink="false">http://dmmd.net/main_wp/?p=1173</guid>
<description>
<![CDATA[Principal Components and Spin Images are two important concepts used heavily in 2D and 3D image processing. Without going into too much detail, here is the intuitive understanding behind the two concepts. Figure 1: Best fitting ellipsoid (solid line) and worst fitting ellipsoid (dotted line) for a set of 2D vectors. First, principal components are [...]]]>
</description>
<content:encoded>
<![CDATA[<p>Principal Components and Spin Images are two important concepts used heavily in 2D and 3D image processing.  Without going into too much detail, here is the intuitive understanding behind the two concepts.</p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/04/Ellipsoid.jpg" alt="" title="Ellipsoid" width="490" height="331" class="aligncenter size-full wp-image-1187" /><br />
Figure 1: Best fitting ellipsoid (solid line) and worst fitting ellipsoid (dotted line) for a set of 2D vectors.</p>
<p>First, principal components are the set of best fitting (i.e. minimizing the mean squared error of the projections) orthogonal basis vectors for a given set S.  Intuitively, this means that if S is a centered set of vectors, as shown in the Figure 1, then the principal components are the axis of the best fitting ellipsoid.  (In Figure 1, this is the solid line ellipsoid.)  The largest eigenvector is the major axis and the smallest eigenvector is the minor axis.  If the set of vectors S is represented as a matrix,  where each column corresponds to a vector, call this matrix S, then the principal components are the eigenvectors of [SS'] where S&#8217; stands for S transpose.  The largest eigenvector corresponds to the largest eigenvalue of [SS'].  (Note: All eigenvectors are usually normalized.  Thus saying &#8220;the largest eigenvector&#8221; means that the vector corresponds to the largest eigenvalue.)</p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/04/Ellipsoid3D.jpg" alt="" title="Ellipsoid3D" width="490" height="401" class="aligncenter size-full wp-image-1190" /><br />
Figure 2: In 3D, the ellipsoid is stretched in 3 different directions, as shown.</p>
<p>Second, spin images are images generated by spinning a plane around the smallest eigenvector of the [SS'] matrix.  This is equivalent to spinning the plane around the normal vector of the best fitting plane, of a 3D set of points (vectors).  As the plane spins around, for each pixel (depending on the resolution of the spin image) it hits a vector.  Each time a pixel hits a vector the count of the pixel increases.  After a 360 degree spin, each pixel will contain the number of vectors it hit.  This is depicted in the Figure below.</p>
<p><img src="http://dmmd.net/main_wp/wp-content/uploads/2011/04/SpinImage1.jpg" alt="" title="SpinImage" width="692" height="344" class="aligncenter size-full wp-image-1200" /><br />
Figure 3: A spin image captures the histogram of the distribution of points as a plane spins around the normal of the best fitting plane.</p>
<p>In 3D, spin images are useful since they are rotationally invariant.  In other words, no matter how the 3D set of vectors are rotated in 3D, the corresponding spin image is the same.  This can be useful for object recognition, matching, registration and other 3D applications.</p>
<p>&#8211; Darian Muresan</p>
]]>
</content:encoded>
<wfw:commentRss>http://dmmd.net/main_wp/intuitive-mathematics/principal-components-and-spin-images/feed/</wfw:commentRss>
<slash:comments>0</slash:comments>
</item>
</channel>
</rss>
<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Minified using memcached
Page Caching using memcached
Database Caching 1/36 queries in 0.005 seconds using memcached
Object Caching 535/608 objects using memcached

Served from: dmmd.net @ 2012-05-18 06:36:39 -->
