Edward Rosten developed the FAST corner detection algorithm and gives several versions of source code. Python code is one of them. I downloaded the Python source code but found there was no example to illustrate the basic usage. Fortunately, the Matlab code has one example m-file. Based on the m-file, I tried to write a Python version and it works.
Showing posts with label study. Show all posts
Showing posts with label study. Show all posts
Monday, July 25, 2011
Sunday, September 20, 2009
[SW] GHMM in Python: importing problem
In July, I installed a library of HMM called GHMM. When I had no experience about Python and therefore ignored the part of Python bindings. With the amazing capabilities of Python+SciPy, I began to notice the possibility to learm more about HMM using the Python bindings of GHMM. Therefore I followed the installation steps on GHMM webpage and got it worked on one of my PC.
Today, I tried to follow the same procedures to install GHMM in my another Ubuntu and Debian system on another two PCs, but got some problems.
After installing the GHMM as well as the Python bindings, I imported ghmm in iPython but got errors:
ImportError: libghmm.so.1: cannot open shared object file: No such file or directory
I tried to find out whether libghmm.so.1 was installed by using
$ sudo updatedb
$ locate libghmm.so.1
then got
~/ghmm/ghmm/.libs/libghmm.so.1
~/ghmm/ghmm/.libs/libghmm.so.1.0.0
/usr/local/lib/libghmm.so.1
/usr/local/lib/libghmm.so.1.0.0
The messages indicated that the libghmm.so.1 had been in my system, but the Python somehow couldn't find it. So there must be some setting needed to make it work.
There have been some discussions in the mailing lists of GHMM as follows.
[Ghmm-list] cant find _ghmmwrapper
[Ghmm-list] ImportError: libghmm.so.1 ...
With the above information, I add the LD_LIBRARY_PATH into .bashrc as
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
It works. :-)
---
Some information found during my solution-searching:
---
memo (090923): I found the libghmm.so.1 file has been in the path of ``/usr/lib/'' instead of ``/usr/local/lib/'' in the first Ubuntu PC which has ghmm installed without any problem. Therefore I tried to cp the libghmm.so.1 file into the path of /usr/lib/ for the other two PCs and everything is okay now.
Today, I tried to follow the same procedures to install GHMM in my another Ubuntu and Debian system on another two PCs, but got some problems.
After installing the GHMM as well as the Python bindings, I imported ghmm in iPython but got errors:
ImportError: libghmm.so.1: cannot open shared object file: No such file or directory
I tried to find out whether libghmm.so.1 was installed by using
$ sudo updatedb
$ locate libghmm.so.1
then got
~/ghmm/ghmm/.libs/libghmm.so.1
~/ghmm/ghmm/.libs/libghmm.so.1.0.0
/usr/local/lib/libghmm.so.1
/usr/local/lib/libghmm.so.1.0.0
The messages indicated that the libghmm.so.1 had been in my system, but the Python somehow couldn't find it. So there must be some setting needed to make it work.
There have been some discussions in the mailing lists of GHMM as follows.
[Ghmm-list] cant find _ghmmwrapper
[Ghmm-list] ImportError: libghmm.so.1 ...
With the above information, I add the LD_LIBRARY_PATH into .bashrc as
export LD_LIBRARY_PATH=$LD_LIBRARY_PATH:/usr/local/lib
It works. :-)
---
Some information found during my solution-searching:
- Understanding imports and PYTHONPATH
- Program Library HOWTO
- LD_LIBRARY_PATH Is Not The Answer
- Why LD_LIBRARY_PATH is bad
---
memo (090923): I found the libghmm.so.1 file has been in the path of ``/usr/lib/'' instead of ``/usr/local/lib/'' in the first Ubuntu PC which has ghmm installed without any problem. Therefore I tried to cp the libghmm.so.1 file into the path of /usr/lib/ for the other two PCs and everything is okay now.
Thursday, September 10, 2009
[Study] Good Fourier Transform explanation
Fourier Transform has been a widely used technique for extracting frequency information from temporal data. But I always wonder how does it work? What makes the FT has such a magical capability?
I thought about FT again yesterday and searched for some online resources. Here is a straightforward explanation of the principle of FT:
The Wavelet Tutorial Part 2 by Robi Polikar
I have to say: The idea of FT is really brilliant. Maybe this is something called ``the beauty of mathematics?'' :-)
---
Other links:
DFT, FFT by Paul Bourke (with C code examples)
FFT in Python by Yukuan (in Chinese)
Discrete Fourier transform by Jang (some content presetnted in Chinese)
I thought about FT again yesterday and searched for some online resources. Here is a straightforward explanation of the principle of FT:
The Wavelet Tutorial Part 2 by Robi Polikar
I have to say: The idea of FT is really brilliant. Maybe this is something called ``the beauty of mathematics?'' :-)
---
Other links:
DFT, FFT by Paul Bourke (with C code examples)
FFT in Python by Yukuan (in Chinese)
Discrete Fourier transform by Jang (some content presetnted in Chinese)
Thursday, July 30, 2009
[SW] HMM source code/library
Two free source code/library of HMM:
I've installed it in my Ubuntu, but still have no time to play with it.
Written by Prof. Dekang Lin. The overall package looks not complex. I've compiled the source code with the included Makefile and the program works normally. I would dive into these code files to learn something about HMM's working principle and how to implement it.
I've installed it in my Ubuntu, but still have no time to play with it.
Written by Prof. Dekang Lin. The overall package looks not complex. I've compiled the source code with the included Makefile and the program works normally. I would dive into these code files to learn something about HMM's working principle and how to implement it.
- Tapas Kanungo's Software Page (found on 2009/08/10)
[Study] Useful websites for pattern recognition
I am learning pattern recognition and want to find useful information for PR beginners like me. Here are something I found and might be helpful:
This is a personal website with abundant content. Dr. Kardi Teknomo introduced some techniques used in PR or ML (machine learning) in a very friendly way. There are still many other topics which I don't know much, and may be also useful if you are searching them.
Lots of links. But the web page reads ``Due to a reorganisation we are not able anymore to maintain these files. They will be removed in the near future.'' I hope they keep maintaining these information if they have web space for it.
(The list might be extended when I find more.)
This is a personal website with abundant content. Dr. Kardi Teknomo introduced some techniques used in PR or ML (machine learning) in a very friendly way. There are still many other topics which I don't know much, and may be also useful if you are searching them.
Lots of links. But the web page reads ``Due to a reorganisation we are not able anymore to maintain these files. They will be removed in the near future.'' I hope they keep maintaining these information if they have web space for it.
- Data Clustering and Pattern Recognition (資料分群與樣式辨認)
(The list might be extended when I find more.)
Subscribe to:
Posts (Atom)