forked from spmallick/learnopencv
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request spmallick#122 from vikasguptaiisc/master
added code for OpenPose multi-person
- Loading branch information
Showing
10 changed files
with
4,038 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
multi-person-openpose | ||
pose/coco/pose_iter_440000.caffemodel | ||
out.* | ||
*.out | ||
debug*.* | ||
*.debug | ||
cpp.jpg | ||
py.jpg |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
cmake_minimum_required(VERSION 2.8.12) | ||
|
||
PROJECT(openPose) | ||
|
||
find_package( OpenCV REQUIRED ) | ||
|
||
include_directories( ${OpenCV_INCLUDE_DIRS}) | ||
|
||
set(CMAKE_CXX_STANDARD 11) | ||
set(CMAKE_CXX_STANDARD_REQUIRED ON) | ||
set(CMAKE_CXX_EXTENSIONS OFF) | ||
|
||
MACRO(add_example name) | ||
ADD_EXECUTABLE(${name} ${name}.cpp) | ||
TARGET_LINK_LIBRARIES(${name} ${OpenCV_LIBS}) | ||
ENDMACRO() | ||
|
||
add_example(multi-person-openpose) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,10 @@ | ||
1. RUN getModels.sh from command line | ||
2. Use the Notebook for better understanding and debugging | ||
3. Download caffe model from http://posefs1.perception.cs.cmu.edu/Users/ZheCao/pose_iter_440000.caffemodel | ||
|
||
Requirements : | ||
1. OpenCV > 3.4.1 | ||
2. Matplotlib for Notebook | ||
|
||
Command to compile the cpp file in ubuntu: | ||
g++ -o3 -std=c++11 multi-person-openpose.cpp `pkg-config --libs --cflags opencv` -lpthread -o multi-person-openpose |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
# ------------------------- BODY, FACE AND HAND MODELS ------------------------- | ||
# Downloading body pose (COCO and MPI), face and hand models | ||
OPENPOSE_URL="http://posefs1.perception.cs.cmu.edu/OpenPose/models/" | ||
POSE_FOLDER="pose/" | ||
FACE_FOLDER="face/" | ||
HAND_FOLDER="hand/" | ||
|
||
# ------------------------- POSE MODELS ------------------------- | ||
# Body (COCO) | ||
COCO_FOLDER=${POSE_FOLDER}"coco/" | ||
COCO_MODEL=${COCO_FOLDER}"pose_iter_440000.caffemodel" | ||
wget -c ${OPENPOSE_URL}${COCO_MODEL} -P ${COCO_FOLDER} | ||
# Alternative: it will not check whether file was fully downloaded | ||
# if [ ! -f $COCO_MODEL ]; then | ||
# wget ${OPENPOSE_URL}$COCO_MODEL -P $COCO_FOLDER | ||
# fi |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.