This blog is focused on GPGPU, OpenCV, OpenGL, Bio-informatics, Segmentation, Livewire and IT news.
Thursday, November 21, 2013
Portico 2.0 windows LAN not working
Create the RTI.rid file with this text and put it in the same directory as your application:
portico.jgroups.loglevel=DEBUG
Run your program and make sure it has read the config file. You should notice messages like this:
DEBUG [SwingWorker-pool-1-thread-1] org.jgroups.protocols.pbcast.GMS: 1T_Porto-36128: installing view [1T_Porto-23855|4] [1T_Porto-23855, 1T_Baggio-57693, 1T_Baggio-6991, 1T_Porto-36128]
DEBUG [SwingWorker-pool-1-thread-1] org.jgroups.protocols.pbcast.STABLE: [ergonomics] setting max_bytes to 16MB (4 members)
DEBUG [SwingWorker-pool-1-thread-1] org.jgroups.protocols.pbcast.FLUSH: 1T_Porto-36128: installing view [1T_Porto-23855|4] [1T_Porto-23855, 1T_Baggio-57693, 1T_Baggio-6991, 1T_Porto-36128]
Now that you are sure it works, do the following to your RTI.rid, in both machines:
portico.jgroups.loglevel=DEBUG
portico.jgroups.udp.address=224.0.0.3
Now it should work. I noticed that using the default address, which is 239.255.20.16, it does not work on my windows network. Changing the address did the trick.
Kind regards and happy open source hla =)
Friday, July 26, 2013
Saturday, June 22, 2013
Indexing
Monday, January 30, 2012
A Maturidade - Rafael Llano Cifuentes

Vejam um pequeno trecho do livro:
A afetividade não está por assim dizer encerrada no coração, nos sentimentos, mas permeia toda a personalidade. Estamos continuamente sentindo aquilo que pensamos e fazemos. Por isso, qualquer distúrbio da vida afetiva acaba por impedir ou pelo menos entravar o amadurecimento da personalidade como um todo.
É significativo verificar como essa imaturidade parece ser uma característica da atual geração. No nosso mundo altamente técnico e cheio de avanços científicos, pouco se tem progredido no conhecimento das profundezas do coração, e daí resulta aquilo que Alexis Carrel, prêmio Nobel de Medicina, apontava no seu célebre trabalho O homem, esse desconhecido: vivemos hoje o drama de um desnível gritante entre o fabuloso progresso técnico e científico e a imaturidade quase infantil no que diz respeito aos sentimentos humanos. Mesmo em pessoas de alto nível intelectual, ocorre um autêntico analfabetismo afetivo: são indivíduos truncados, incompletos, mal-formados, imaturos; estão preparados para trabalhar de forma eficiente, mas são absolutamente incapazes de amar. Esta desproporção tem conseqüências devastadoras: basta reparar na facilidade com que as pessoas se casam e se "descasam", se "juntam" e se separam. Dão a impressão de reparar apenas na camada epidérmica do amor e de não aprofundar nos valores do coração humano e nas leis do verdadeiro amor. Quais são, então, os valores do verdadeiro amor? Que significado tem essa palavra? O amor, na realidade, tem um significado polivalente, tão dificil de definir que já houve quem dissesse que o amor é aquilo que se sente quando se ama, e, se perguntássemos o que se sente quando se ama, só seria possível responder simplesmente: "Amor". Este círculo vicioso deve-se ao que o insigne médico e pensador Gregório Marañon descrevia com precisão: "O amor é algo muito complexo e variado; chama-se amor a muitas coisas que são muito diferentes, mesmo que a sua raiz seja a mesma". A imaturidade no amor Hoje, considera-se a satisfação sexual autocentrada como a expressão mais importante do amor. Não o entendia assim o pensamento clássico, que considerava o amor da mãe pelos filhos como o paradigma de todos os tipos de amor: o amor que prefere o bem da pessoa amada ao próprio. Este conceito, perpassando os séculos, permitiu que até um pensador como Hegel, que tem pouco de cristão, afirmasse que "a verdadeira essência do amor consiste em esquecer-se no outro". Bem diferente é o conceito de amor que se cultua na nossa época. Parece que se retrocedeu a uma espécie de adolescência da humanidade, onde o que mais conta é o prazer. Este fenômeno tem inúmeras manifestações. Referir-nos-emos apenas a algumas delas:
Há pouco, um amigo, professor de uma Faculdade de Jornalismo, referiu-me um episódio relacionado com um seu primo - extremamente egoísta - que se tinha casado e separado três vezes. No cartão de Natal, após desejar-lhe boas festas, esse professor perguntava-lhe em que situação afetiva se encontrava. Recebeu uma resposta chocante: "Assino eu e a minha gata. Como ela não sabe assinar, o faz estampando a sua pata no cartão: são as suas marcas digitais. Este animalzinho é o único que quer permanecer ao meu lado. É o único que me ama". O imaturo pretende introduzir o outro no seu projeto pessoal de vida, em vez de tentar contribuir com o outro num projeto construído em comum. A felicidade do cônjuge, da família e dos filhos: esse é o projeto comum do verdadeiro amor. As pessoas imaturas não compreendem que a dedicação aos filhos constitui um fator importante para a estabilidade afetiva dos pais. Também não assimilaram a idéia de que, para se realizarem a si mesmos, têm de se empenhar na realização do cônjuge. Quem não é solidário termina solitário. Ou juntando-se a uma "gatinha", seja de que espécie for. |
Saturday, June 11, 2011
OpenCV 2 Computer Vision Application Programming Cookbook
So, I was reviewing this brand new OpenCV book, from Robert Laganière, which is just amazing. It seems to be the best update to Bradsky and Kaehler's well known "Learning OpenCV", as it focus on OpenCV 2.0.
For someone looking for an updated reference in OpenCV, one will find lots of the new C++ API coverage, as well as a nice chapter 8 covering "Detecting and Matching Interest Points", including FAST, SIFT, and SURF features, which are a must for such a fully featured library as OpenCV.
Besides the attention paid to new topics, there's a good setup explanation for Qt and Visual Studio.
All topics are covered in a straight to the point methodology which makes of it an easy guide to consult for several topics of OpenCV.
The only drawback of the book would be not even mentioning OpenCV's Python API, which is great for prototyping.
All in all, this is a great book and it came to fulfill the needs of an OpenCV 2.0 reference the computer vision community was looking for.
Saturday, January 30, 2010
Palestras da CP 2010
Realidade aumentada com ARToolkit
Processamento de Imagens para Robótica com OpenCV e RoboRealm
Realidade Aumentada com Unity3D (Unity3d Augmented Reality)
Monday, January 04, 2010
Se queres paz...
Thursday, December 03, 2009
Visita ao CPTEC
Nossa, hoje fiquei realmente impressionado. Graças ao fenomenal professor Jairo Panetta, pude ir conhecer o Centro de Previsões de Tempo e Estudos Climáticos do INPE, um dos poucos lugares com supercomputadores aqui no Brasil.
Foi um prazer conhecer desde o SX3 ao Cluster 1100, passando pelo Tatuí e outros. Queria deixar os meus parabéns para toda a equipe de pesquisadores e funcionários do CPTEC.
Sei que este post merece ser bem maior, mas queria pelo menos agora deixar algo registrado aqui. :)
Iremos tentar colocar parte do modelo de previsão de tempo rodando em um cluster de PlayStations 3, na arquitetura Cell. Por favor, confiram as novidades no site do projeto: http://code.google.com/p/ps3hacking
Tuesday, October 27, 2009
VisionBlaster lança código de integração entre Unity3D e headtracking
Saturday, October 10, 2009
Games and Teaching
A book about it Games and simulations in online learning: research and development frameworks
An article discussing the fear of games: http://net.educause.edu/ir/library/pdf/eqm0830.pdf
Another great one: https://www.iste.org/Content/NavigationMenu/EducatorResources/YourLearningJourney/CreativityandInnovation/jrte-40-1-023-gro.pdf
Now, some focus on useful games: http://www.gamesforchange.org/
Another great example of using games is showing abuse felt by some people and letting the whole world know about it. I personally enjoyed the idea of Darfur is Dying. Check the cool game here.
It seems Channel 4 has some experience in it: http://www.channel4learning.com/
There's an article about it here:
Thursday, September 10, 2009
Unity3d em São Paulo
http://visionblaster.com/cms/index.php?option=com_content&view=section&layout=blog&id=11&Itemid=59&lang=pt
"A VisionBlaster cria jogos em Unity3D de acordo com os seus requisitos, seja um AdverGame, algum jogo de caráter educativo ou mesmo algum aplicativo cujo visual precisa ser feito em 3 dimensões (3D)."
Outras empresas, como a AlphaChannel já estão dando treinamento: http://www.alphachannel.com.br/noticia.php?id=259 . Esta tecnologia realmente promete.
Monday, April 13, 2009
Filtrando imagens apelativas com 'Olha o nível!'

Sabe-se que atualmente muitos seqüestros de crianças estão ligados à pornografia infantil. O próprio artigo 70 do Estatuto da Criança deixa claro:
'Art. 70. É dever de todos prevenir a ocorrência de ameaça ou violação dos direitos da criança e do adolescente. (Estatuto da Criança e do Adolescente - LEI Nº 8.069, DE 13 DE JULHO DE 1990.)'
Visando evitar a dissipação de tais imagens, bem como diminuir o caráter apelativo de diversos sites através de imagens de violência e lembrando que a internet é uma mídia interativa, o serviço 'Olha o nível!' foi criado.
Através do site: http://olha-o-nivel.appspot.com/ , pode-se baixar um plugin para o Firefox que bloqueia o aparecimento de tais imagens em uma navegação, de forma colaborativa. Assim que alguém que tenha visto alguma imagem apelativa na internet, pode reportar tal imagem para o site (clicando com o botão direito e selecionando 'Olha o nível!') de forma que outras pessoas que tenham instalado a ferramenta evitarão automaticamente o carregamento destas imagens. Desta forma, as estatísticas de carregamento de imagens apelativas irão diminuir, forçando os produtores de conteúdo a mudar o enfoque de seus sites. É claro, a ferramenta só fará sentido com um número razoável de usuários.
De qualquer forma, fica a dica: http://olha-o-nivel.appspot.com/
Tuesday, March 24, 2009
Python mouse move in 5 lines of code (Linux only)
d = display.Display()
s = d.screen()
root = s.root
root.warp_pointer(300,300)
d.sync()

Friday, February 27, 2009
ImageJ LiveWire plugin updates
It was about time to update LiveWire to catch up with newer versions of ImageJ.
The new release is here: http://sourceforge.net/projects/ivussnakes
For a more updated documentation, one should check: http://imagejdocu.tudor.lu/doku.php?id=plugin:segmentation:livewire_plugin:start
I hope it is still useful. Please, write me back in case you've found some installation problems.
I'm also looking for someone who wishes to integrate it to the official tree of ImageJ.

Monday, January 26, 2009
In the middle of bits, PWMs, wires, resin, and electromagnetic waves, TORP (CP01) was born...

January, 25th, around 8:00 pm, during Campus Party 2009, that's when TORP was firstly fully assembled for the first time.
The project aimed at building the first humanoid open source robot in Brazil and it was called TORP (www.theopenrobotproject.org).
The idea was to create a robot that would work as a study platform whose modules would be able to be hot plugged and they could also be interchangeable, since it's hard to unplug a hand from one robot and to couple it to another because of the lack of standards.
Without prior support from public research funds, CP01 (the name of the first assembled version of TORP) was sponsored by several institutes and industries, namely: E3 Futura, Instituto Tecnológico de Aeronáutica, Universidade do Estado de São Paulo, Micropress, RIMA and Campus Party.
For more information about the project, I'd suggest taking a look at http://www.theopenrobotproject.org/ .
I'd really like to thank everyone from the team (please remind me if I've forgotten someone, specially contributers from Campus Party, whose names I couldn't take note):
Alan Morgensztern, Alexandre Simões, Esther Colombini, Guilherme Andrade, Jackson Paul Matsuura, Kauê Silva, Maira, Marcelo Franchin, Melissa Sanchez Freitas, Paulo Vitor Lima, Rafael Ribeiro da Silva, Rafael Toschi Chiafarelli, Ronaldo Carrion, Victor Nalin, and my girlfriend Kathy for all the support. Thanks for my bro and Dé for being there as well :)
And thank You, God, of course, for everything running smoothly :)
If there's anyone interested in the lecture about Computer Vision, here's a link to it (Portuguese only... in case you want it in English, please leave a comment):
http://www.slideshare.net/dannyxyz22/campus-party-computer-vision-presentation
I've tried to gather all news about the project here:
http://tecnologia.terra.com.br/interna/0,,OI3470641-EI12933,00.html
http://oglobo.globo.com/tecnologia/mat/2009/01/25/apresentado-na-campus-party-primeiro-robo-livre-do-mundo-754136596.asp
http://www.gluon.com.br/blog/2009/01/25/noite-de-premiacao-na-campus-party-2009/
http://colunistas.ig.com.br/tecnologia/2009/01/24/cp01-nasce-ao-vivo-na-campus-party/
http://www.ita.br/online/2009/noticias09/campusparty.htm
http://www.unesp.br/int_noticia_2imgs.php?artigo=4041
For photos:
http://www.flickr.com/photos/33142604@N00/tags/campus/
Please, leave your comment about TORP, we'd love to hear your feedback!
Thursday, January 15, 2009
TORP - The Open Robot Project
Make sure you'll check it out at Campus Party Brasil '09 :)
Tuesday, January 13, 2009
Compiling OpenCV for Gumstix
In order to compile OpenCV for Gumstix, firstly one needs to download it from:
http://sourceforge.net/project/showfiles.php?group_id=22870
The version I've testes was opencv-linux 1.1pre1, but I believe any other release will barely follow the same ideas provided here.
After the file has been extracted (tar -xzvf opencv-1.1pre1.tar.gz), one should configure the environment variables for the compiler:
export CC=/home/developer/gumstix/gumstix-oe/tmp/cross/bin/arm-angstrom-linux-gnueabi-gcc
export CXX=/home/developer/gumstix/gumstix-oe/tmp/cross/bin/arm-angstrom-linux-gnueabi-g++
$ ./configure --host=arm-linux --build=i686-linux --prefix=/home/developer/opencvgum --without-gthread --without-gtk --without-python --disable-apps
Notice that we've defined that the prefix=/home/developer/opencvgum is the place it will be installed when we type 'make install'. By the way, make sure you have created this directory.
Be sure to substitute the /home/developer path to your user path, as well as the /gumstix/gumstix-oe/ to your installed gumstix environment.
We've also disabled the gtk environment since we are not interested in running the GUI applications inside the gumstix. I've also disabled python and building the applications.
Now that configuration has been successful. Type:
$ make
And then:
$ make install
If everything went well, you'll have the binaries and samples installed to /home/developer/opencvgum
Now, it would be useful to try and compile the samples so that we are sure they will run in the Gumstix.
In order to build them, go to /home/developer/opencvgum/share/opencv/samples/c and edit the build_all.sh script.
Make it executable:
$chmod +x ./build_all.sh
And then change all gcc and g++ to its arm-likes. My build_all.sh ended up like this:
#!/bin/sh
export PKG_CONFIG_PATH=/home/developer/opencvgum/lib/pkgconfig/
if [[ $# > 0 ]] ; then
base=`basename $1 .c`
echo "compiling $base"
/home/developer/gumstix/gumstix-oe/tmp/cross/bin/arm-angstrom-linux-gnueabi-gcc -ggdb `pkg-config opencv --cflags --libs` $base.c -o $base
else
for i in *.c; do
echo "compiling $i"
/home/developer/gumstix/gumstix-oe/tmp/cross/bin/arm-angstrom-linux-gnueabi-gcc -ggdb `pkg-config --cflags opencv` -o `basename $i .c` $i `pkg-config --libs opencv`;
done
for i in *.cpp; do
echo "compiling $i"
/home/developer/gumstix/gumstix-oe/tmp/cross/bin/arm-angstrom-linux-gnueabi-g++ -ggdb `pkg-config --cflags opencv` -o `basename $i .cpp` $i `pkg-config --libs opencv`;
done
fi
Notice that we've also defined the export PKG_CONFIG_PATH=/home/developer/opencvgum/lib/pkgconfig/ so that the correct includes and linked libraries are built correctly.
Run this command and you'll notice the executable files will be created. I think that if you don't disable the flag "--disable-apps" in the configure application and make this change to the build_all.sh earlier it might also work.
Well, now that OpenCV has been built, you should be able to copy it to your gumstix. There's a small problem though. If you compact the files, you'll notice it's very big, so, a good idea is to delete a couple files we are sure we are not going to use.
An advice would be to delete some of the haarcascades.
Choose some of them you are sure you won't use, like the haarcascade_profileface.xml inside the data sub-directory, for instance. Delete a couple others as well.
This way, you'll be able to create a .tar.gz of around 6.5MB.
When it's done, copy it to your gumstix through scp:
$scp opencvgum.tar.gz root@192.168.YOUR-GUM.IP:/tmp
Make sure you copy it to /tmp, because you'll probably be out of space copying it somewhere else.
Extract it and then try to run one of the demos that does not use windows... the ./letter_recog application, for instance... it's located at:
/tmp/opencvgum/share/opencv/samples/c
Well, you might be able to see it running. Else, some libstdc++.so is missing error could also happen.
This means you don't have this library installed. One easy way to install it is through the command
$ipkg install libstdc++6
In case some other libraries are missing as well, repeat the procedure with their names. Notice that some packages have odd names.
For instance, if you had typed:
$ root@gumstix-custom-verdex:/usr/share$ ipkg install libstdc++
Then you'd have received the following message:
Nothing to be done
An error ocurred, return value: 4.
Collected errors:
Cannot find package libstdc++.
Check the spelling or perhaps run 'ipkg update'
Actually the name of the library is libstdc++6. Make sure you type the correct library name.
Well, in case libstdc++ is really installed, you might as well get some error like:
./letter_recog: error while loading shared libraries: libcxcore.so.2: cannot open shared object file: No such file or directory
It means the LD_LIBRARY_PATH is not pointing at your opencv libraries.
Simply type:
$ export LD_LIBRARY_PATH=/tmp/opencvgum/lib/
You will eventually be able to run your letter_recognition application.
Well, in case you want to run other applications, like the face recognition one, make sure you disable the GUI related functions and write your results to files.
We'll be able to see it working at Campus-Party Brasil
Make sure you'll be there!
Gumstix UVC drivers
It requires that the steps in this wiki have been performed.
Firstly check-out the old driver sources from:
svn co svn://svn.berlios.de/linux-uvc/linux-uvc/trunk
After file checkout, one should change the Makefile.
Change the KERNEL_DIR var to point to your gumstix kernel path, as in:
KERNEL_DIR :=
/home/developer/gumstix/gumstix-oe/tmp/work/gumstix-custom-verdex-angstrom-linux-gnueabi/gumstix-kernel-2.6.21-r1/linux-2.6.21/
Define the CROSS_COMPILE var:
CROSS_COMPILE := /home/developer/gumstix/gumstix-oe/tmp/cross/bin/arm-angstrom-linux-gnueabi-
Change make lines so that they include your CROSS_COMPILE and ARCH=arm vars:
From:
@(make -C $(KERNEL_DIR) M=$(PWD) CROSS_COMPILE=$(CROSS_COMPILE) modules)
to:
@(make -C $(KERNEL_DIR) M=$(PWD) ARCH=arm CROSS_COMPILE=$(CROSS_COMPILE) modules)
And from:
@(make -C $(KERNEL_DIR) M=$(PWD) INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) INSTALL_MOD_PATH=$(INSTALL_MOD_PATH) modules_install)
to:
@(make -C $(KERNEL_DIR) M=$(PWD) ARCH=arm
INSTALL_MOD_DIR=$(INSTALL_MOD_DIR) INSTALL_MOD_PATH=$(INSTALL_MOD_PATH)
modules_install)
Now, type make uvcvideo
The file uvcvideo.ko is built. This file should be copied to /lib/modules/2.6.21/kernel/drivers/media/video/uvcvideo.ko
Nevertheless, if you type make, you'll notice a message like:
-------------------------------- WARNING ---------------------------------------
The USB Video Class driver has moved to http://linuxtv.org/.
Using the Berlios SVN repository is now deprecated.
Please check http://linux-uvc.berlios.de/ for download instructions.
If you really want to compile this historical version, run 'make uvcvideo'.
--------------------------------------------------------------------------------
which tells us that we are using deprecated files for the driver.
I've tried to use the latest drivers from the Mercurial clone repository, but I'm getting this error:
"/home/developer/uvc-new/uvcvideo-90c7dc24fb4d/v4l/cx18-driver.h:65:4: error: #error "This driver requires kernel PCI support." "
In order to build it, I've changed the root Makefile to:
CROSS_COMPILE := /home/developer/gumstix/gumstix-oe/tmp/cross/bin/arm-angstrom-linux-gnueabi-
install:
$(MAKE) -C $(BUILD_DIR) ARCH=arm CROSS_COMPILE=$(CROSS_COMPILE) install
%::
$(MAKE) -C $(BUILD_DIR) ARCH=arm CROSS_COMPILE=$(CROSS_COMPILE) $(MAKECMDGOALS)
And the v4l/Makefile to:
OUTDIR ?= /home/developer/gumstix/gumstix-oe/tmp/work/gumstix-custom-verdex-angstrom-linux-gnueabi/gumstix-kernel-2.6.21-r1/image/lib/modules/2.6.21/build
SRCDIR ?= /home/developer/gumstix/gumstix-oe/tmp/work/gumstix-custom-verdex-angstrom-linux-gnueabi/gumstix-kernel-2.6.21-r1/image/lib/modules/2.6.21/source
I've tried to issue some "make -i" command, but I doubt it will work. If you've made any progress with the new drivers, feel free to comment.
The old drivers have worked pretty fine as well.
Thursday, December 04, 2008
Adobe Flex and Flash Face detection library
Just wondering how many of you are also looking for it.
[]'s
Wednesday, September 17, 2008
EHCI 0.5 is now ready for PyCon Brasil 2008
Ehci 0.5 has just been released and it now features Python bindings.
It's pretty easy to use EHCI in Python. The following snippet shows how to do it in 6 lines:
import ehci
ehci.ehciInit()
while(1):
ehci.ehciLoop(1,0)
x,y,width,height = ehci.getHeadBounds()
print "Coord (",x,",",y,") width ",width,"height ",height
These two videos give some idea of EHCI integration with Panda3D:
To download it, check http://code.google.com/p/ehci