Git Product home page Git Product logo

matlab-yolov2-livetracking's Introduction

YOLOv2 for MatLab

YOLOv2 for Matlab is a fork of the Matlab MEX wrapper Yolomex by Ignacio Rocco with Matlab demos for LED control and people tracking.

screenshot

  • This is using the original darknet framework, so it's meant to run on Unix (OSX/Linux).
  • openMP is not included into gcc in OSX - you can still use your own compiler.
  • Don't be stupid: change paths, if you're using different versions!

Install

0. Clone

git clone --recursive https://github.com/kbitr/matlab-yolov2

1. Edit Makefile

  • Adjust CC path (OSX)
  • CUDA: Set "GPU=1"
  • openMP: Set "OPENMP=1"
make

2. Compile yolomex (in Matlab)

CUDA:

mex -I./darknet/include/ -I./darknet/src CFLAGS='-Wall -Wfatal-errors -Wno-unused-result -fPIC' -L. -lyolo -L/usr/local/cuda/lib64 -lcudart -lcublas -lcurand yolomex.c

CPU:

mex -I./darknet/include/ -I./darknet/src/ -L. -lyolo yolomex.c

4. Run Demo

main*.m

OSX's Clang can't compile openMP?

Well, yeah - just install LLVM.

brew install llvm
  • The following overwrites the mex-compiler config for c-files!
  • It's recommended to store the clang_openmp_maci64.xml in ~/Library/Application Support/MathWorks/MATLAB/R2017b.
  • Adjust path in the below command if necessary
mex -setup:'~/Library/Application Support/MathWorks/MATLAB/R2017b/clang_openmp_maci64.xml' C

Your Matlab crashes when using CUDA?

That happens when your GPU is running out of memory, since Matlab isn't aware of the memory usage. You should reduce the the batch value .cfg-file to a lower multiple of 32. (But other values work as well.)

By the way, for speeding up the detection you can reduce the width and height.

matlab-yolov2-livetracking's People

Contributors

kbitr avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

matlab-yolov2-livetracking's Issues

how to run this commend ?

when i run this commend : mex -I./darknet/include/ -I./darknet/src/ -L. -lyolo yolomex.c
it will show the error below

Error using mex
MEX cannot find library 'yolo', specified with the -l option.
MEX searched for a file with one of the following names:
libyolo.a
yolo.lib
libyolo.lib
Verify the library name is correct. If the library is not
on the existing path, specify the path with the -L option.

did I lack some file ? or I have to produce this three by my self?

thanks for help me.

No weightfiles provided in the folder

Hello, when I run 'mainFile.m', 'weightfile' used for initializing yolo can not find in the repository. Could you provide the weightfile for me? Thank you for your help :)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.