Ask Your Question
1

Where to place the pretrained data for GOTURN tracker

asked 2017-01-25 09:55:55 -0600

00Zetti gravatar image

Hi,
following the documentation

//In order to use GOTURN tracker, GOTURN architecture goturn.prototxt and goturn.caffemodel are required to exist in root folder.

I have to put the pre trained caffemodel and the goturn.prototxt into the root folder, but which root? I've tried so far:

  • openCV src dir (github contrib repo/ + contrib/modules/tracking/+subfolders
  • opencv build dir(similar directories here)
  • opencv dirs in /usr/local/lib+include+bin
  • project src and project build

I am sure there is someone who successfully used it and can help me with this easy question :)

edit retag flag offensive close merge delete

Comments

You can see here the code to load the Caffe models. Have you tried to put the files in the same directory than the executable?

Eduardo gravatar imageEduardo ( 2017-01-25 11:42:00 -0600 )edit

Yep, that's exactly what I tried :D Maybe there is more to do than just drop these two files? Or do I need to rebuild openCV with the fhe files instead of just placing them afterwards?

00Zetti gravatar image00Zetti ( 2017-01-25 12:18:15 -0600 )edit

Where to place the pretrained data for GOTURN tracker in Android project? @nrparikh@00Zetti

rainY gravatar imagerainY ( 2018-07-27 03:22:00 -0600 )edit

@rainY , please do not post answers here, if you have a question or comment, thank you.

berak gravatar imageberak ( 2018-07-27 04:10:30 -0600 )edit

@berak OK, Do you know this question?

rainY gravatar imagerainY ( 2018-07-27 04:14:24 -0600 )edit

it has to be in the same folder, where your program runs. where that is on android -- no idea.

berak gravatar imageberak ( 2018-07-27 04:47:47 -0600 )edit

2 answers

Sort by ยป oldest newest most voted
2

answered 2017-01-28 07:47:32 -0600

00Zetti gravatar image

updated 2017-01-30 03:55:27 -0600

Ok problem solved :D
I could fix it by myself. Like suggested in the comment and what I've already tried - it was the right path. The problem was, that I didn't have the access rights for this folder, now it works fine.


So for others a simple tutorial how to get the files and where to place.

  • download and extract pre-trained data
  • copy them to /.../opencv_contrib-master/modules/tracking/src/
  • make sure you have access rights to this folder (e.g. sudo chmod -R on your opencv Folder)
edit flag offensive delete link more

Comments

It's still not clear to me which in what directory should the caffemodel and the goturn.prototxt be placed? Should be the same directory as the generated executable or should be the source directory of opencv_contrib and then rebuild the opencv library?

mihaicl gravatar imagemihaicl ( 2017-04-04 13:20:04 -0600 )edit
0

answered 2017-08-04 13:39:04 -0600

nrparikh gravatar image

The method suggested by 00zetti is correct. If still facing issues, please ensure following points:

  • You have concatenated the zip files into single file named "goturn.caffemodel"
  • You need to paste both files i.e. "goturn.protoxt" and "goturn.caffemodel" in your working directory. You can check your working directory using getcwd() command.

Credits to LBerger.

edit flag offensive delete link more

Question Tools

1 follower

Stats

Asked: 2017-01-25 09:55:55 -0600

Seen: 4,904 times

Last updated: Jul 27 '18