How can I plot a PR curve produced by scoreDetections?
The following Matlab code will produce nicely formatted PR curves.
curve = dlmread(FILENAME, ',', 1, 0); plot(curve(:, 2), curve(:, 3), 'b-', 'LineWidth', 2); axis([0 1 0 1]); grid on; xlabel('recall'); ylabel('precision');
How can I set my editor to replace tabs with spaces?
If you're using emacs add the following to your .emacs file:
(setq c-basic-offset 4) (setq tab-width 4 indent-tabs-mode nil) (setq-default indent-tabs-mode nil)
If you're using Microsoft Visual Studio:
What is the format of the data that pointCloudViewer reads?
The format of the data read by pointCloudViewer is a
10-element vector per point containing location (x y z),
normal (nx ny nz), color (r g b) normalized
between 0 and 1, and arbitrary weight (w). You can also
import point cloud files containing on location only (x y z)
using File|Import....
I have pre-compiled 32-bit .mexglx Matlab functions. Can I use these on a 64-bit machine?
Yes, invoke Matlab with:
matlab -glnx86
OPENCV_CFLAGS += /usr/local/include/opencv/ OPENCV_LFLAGS += /usr/local/lib/I can't get OpenCV to find my installed version of ffmpeg.
if test x"$with_ffmpeg" = "xyes"; then AC_CHECK_HEADER(ffmpeg/avcodec.h, AC_CHECK_LIB(avcodec, avcodec_decode_video, [ AC_CHECK_LIB(avformat, av_open_input_file, [ have_ffmpeg=yes AC_DEFINE(HAVE_FFMPEG,,[FFMpeg video library]) FFMPEGLIBS="-lavcodec -lavformat" ], [ have_ffmpeg=no ], [-lavcodec]) ], [ have_ffmpeg=no ]), [ have_ffmpeg=no ]) elseto
if test x"$with_ffmpeg" = "xyes"; then AC_CHECK_HEADER(ffmpeg/avcodec.h, [ have_ffmpeg=yes AC_DEFINE(HAVE_FFMPEG,,[FFMpeg video library]) FFMPEGLIBS="-lavcodec -lavformat" ], [ have_ffmpeg=no ]) elseNow re-configure and re-make OpenCV:
autoconf ./configure --enable-static --without-quicktime --with-ffmpeg \ CXXFLAGS=-I<FFMPEG_INCLDUE_PATH> CFLAGS=-I<FFMPEG_INCLUDE_PATH> CPPFLAGS=-I<FFMPEG_INCLUDE_PATH> LDFLAGS=-L<FFMPEG_LIB_PATH> make make install
If the above does not work, or you cannot find the corresponding section within your configure.in script, try commenting out one of the last lines in external/opencv-1.0.0/otherlibs/highgui/cvcap_ffmpeg.cpp:
if (!(mywriter->fmt->flags & AVFMT_NOFILE)) { /* close the output file */ //url_fclose(&mywriter->oc->pb); }Error loading shared libraries.
How can I compile for 32-bit linux on a 64-bit system?
Create a file called make.local in the root SVL directory and add the line
FORCE32BIT = 1
Building the Matlab mex Applications.
By default the Matlab mex applications are not built. This is because not all
systems will have Matlab installed. To build the mex applications automatically
create a file called make.local in the root SVL directory and add the line
BUILD_MEX_APPS = 1
The pointCloudViewer runs, but does not show anything.
You probably need to install a whole lot of OpenGL libraries.
OpenCV 1.0 fails to compile on Ubuntu 9.10 (with gcc 4.4)
If you get the following error message:
../../cxcore/include/cxmisc.h:133:6: error: #elif with no expression
wxWidgets fails to compile on Ubuntu 9.10
If you get the following error message:
Error: ./include/wx/gsocket.h:40: error: using typedef-name 'GSocket' after 'class' /usr/include/glib-2.0/gio/giotypes.h:120: error: 'GSocket' has a previous declaration here
I can't get a video to play in OpenCV?
Make sure the video is encoded with a codec installed on your
machine. You can find a bunch of video codecs for Windows at
K-Lite
Codec Pack. Other useful software for converting between video
formats in Windows is Video Converter.
I get the error, Error: Could not detect a compiler on local system which can compile the specified input file(s) at C:\MATLAB7/bin/win32/mexsetup.pm line 519., while trying to compile a mex file using the mex command in MATLAB
You will need to run mex -setup in MATLAB to specify the C++
compiler MATLAB is to use.