## Sunday, December 13, 2009

### ChromeEye, a TinEye extension for Google Chrome

I made a simple reverse image search extension for Google Chrome. Reverse what? Reverse image search. Think Google, but instead of text you enter an image. Ah okay. Please continue.

The ChromeEye extension uses the image search engine TinEye, whose technology allows you to find exact copies of images (including scalings and slight distortions).

Version 0.1 of ChromeEye (updated: now latest version) basically mimics the TinEye bookmarklet behavior, i.e. it lists all images of the current page with links to TinEye results. Let's hope Google Chrome allows for editing the browser context menu soon, so you can right click and select a "Search Image on TinEye".

Meanwhile, you can download the latest version of ChromeEye directly from this link, while the complete source code is available on GitHub. So until the oficial TinEye plugin gets released, have fun with this easy solution.

Update 14 December 2009: ChromeEye now has a page on the google chrome extensions site. Version 0.2 was also released, with a nicer logo.

Update 17 June 2011: ChromeEye is now called Reveye and it includes different search engines, such as Google, Tineye and Cydral.

## Friday, December 04, 2009

### Drawing beautiful block diagrams in LaTeX

I used to put together the illustrations in my publications with a mixture of Inkscape, CorelDraw and psfrag, but obviously this couldn't continue for a long time without becoming an insult to graphic design.

For my latest writings I am returning to the basics: PSTricks. (I know there are lots of other programs to draw block diagrams, but I didn't find any that allowed enough customization). To avoid starting from zero, I am using the PSTricks Signals and Systems package (pst-sigsys), which is easy to customize if you keep the PSTricks user guide (pdf) at hand.

Here's a simple example:
\documentclass{article}\usepackage{pst-sigsys}\pagestyle{empty}\begin{document}\begin{figure}[ht]\centering %\begin{pspicture}[showgrid=false](0.5,-1.2)(9,1.55)%--- Define blocks ---\rput(0.5,0){\rnode{s}{$s[n]$}}\dotnode[dotstyle=square*,dotscale=0.001](1.7,0){dot}\psblock(3,.75){H1}{$H_1(z)$}\psblock(3,-.75){H2}{$H_2(z)$}\psblock(5.8,.75){B2}{$\hat H_2(z)$}\psblock(5.8,-.75){B1}{$\hat H_1(z)$}\pscircleop(7.7,0){ominus}\rput(9,0){\rnode{e}{$e[n]$}}%--- Connect blocks ---\psset{style=Arrow}\ncline[nodesepA=.15]{-}{s}{dot}\ncangle[angleA=90,angleB=180]{dot}{H1}\ncangle[angleA=-90,angleB=180]{dot}{H2}\ncline{H1}{B2} \naput[npos=.5]{$x_1[n]$}\ncline{H2}{B1} \naput[npos=.5]{$x_2[n]$}\ncangle[angleB=90]{B2}{ominus} \naput[npos=.5]{$z_1[n]$}\ncangle[angleB=-90]{B1}{ominus} \naput[npos=.5]{$z_2[n]$}\ncline[nodesepB=.15]{ominus}{e}\end{pspicture}\end{figure}\end{document}
which, after some retouching of the .sty file produces this pretty diagram:

Update 6th December 2009: Here's a slightly more complicated diagram, based on the same codes as the above example.