GithubHelp home page GithubHelp logo

bobrown / deeparsing Goto Github PK

View Code? Open in Web Editor NEW
21.0 3.0 6.0 7.82 MB

human paring project based on caffe tools

License: Other

CMake 2.51% Makefile 0.63% C++ 78.35% C 0.16% MATLAB 3.57% M 0.01% Shell 0.49% Python 7.86% sed 0.02% Cuda 6.39% Limbo 0.01%

deeparsing's Introduction

Deeparsing Workshop

This is a human parsing project based on caffe tools.

This project is to parse human body and output the binary picture. The pixel of Human body is 255, and background is 0. The running time of this code is 100ms/batch on 1080ti GPU.

The basic CNN backbone employs PSPNet. Technical details are in the paper: [Pyramid Scene Parsing Network](https://arxiv.org/abs/1612.01105)

Installation:

For installation, cuDNN version should less than cuDNN v4. If you use cuda8.0, then could not support cuDNN v4.

Install matio:

download matio-1.5.2.tar.gz https://sourceforge.net/projects/matio/files/matio/1.5.2/

$ tar zxf matio-X.Y.Z.tar.gz

$ cd matio-X.Y.Z

$ ./configure

$ make

$ make check

$ sudo make install

Install caffe:

$ cd deeparsing-master

$ make -j32 && make pycaffe -j32

How to use this project:

(1) cd the exper dir:

$ cd deeparsing-master/exper

(2) download the weights and network files

Link: https://pan.baidu.com/s/1h3oF0LUsv_6Ub-CLghKjEw CODE: i1ja

(3) saved weights in the deeparsing-master/exper/config folder

$ mv parsing_v2.caffemodel deeparsing-master/exper/config

$ mv deploy_v2.prototxt deeparsing-master/exper/config

(4) testing the dataset

$ cd deeparsing-master/exper

$ python test.py --data_dir "dir of test set" --gpu_id 0

(5) looking into the resulting images

$ cd deeparsing-master/exper/deeparsing

$ ls

Other Scripts:

Many useful scripts for human parsing task are saved in the deeparsing-master/exper folder.

For examples:

convert_parsing_label.py : convert the label of each image to another value

gen_lists_from_folder.py : get list file from the image folder

gen_train_val_from_lists.py : create train.txt and val.txt file from the list file, that is useful for training our models.

Some Results:

original img

parsing img

deeparsing's People

Stargazers

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

Watchers

 avatar  avatar  avatar

deeparsing's Issues

caffe install failed

when I run "make -j14 && make pycaffe -j14"

PROTOC src/caffe/proto/caffe.proto
CXX src/caffe/layer.cpp
CXX src/caffe/data_reader.cpp
CXX src/caffe/internal_thread.cpp
CXX src/caffe/layer_factory.cpp
CXX src/caffe/data_transformer.cpp
CXX src/caffe/layers/im2col_layer.cpp
CXX src/caffe/layers/log_layer.cpp
CXX src/caffe/layers/power_layer.cpp
CXX src/caffe/layers/multinomial_logistic_loss_layer.cpp
CXX src/caffe/layers/concat_layer.cpp
CXX src/caffe/layers/densecrf_layer.cpp
CXX src/caffe/layers/spatial_product_layer.cpp
CXX src/caffe/layers/cudnn_bn_layer.cpp
CXX src/caffe/layers/dummy_data_layer.cpp
src/caffe/internal_thread.cpp:1:10: fatal error: boost/thread.hpp: No such file or directory
1 | #include <boost/thread.hpp>
| ^~~~~~~~~~~~~~~~~~
compilation terminated.
src/caffe/layer.cpp:1:10: fatal error: boost/thread.hpp: No such file or directory
1 | #include <boost/thread.hpp>
| ^~~~~~~~~~~~~~~~~~
compilation terminated.
src/caffe/data_reader.cpp:1:10: fatal error: boost/thread.hpp: No such file or directory
1 | #include <boost/thread.hpp>
| ^~~~~~~~~~~~~~~~~~
compilation terminated.
src/caffe/data_transformer.cpp:2:10: fatal error: opencv2/core/core.hpp: No such file or directory
2 | #include <opencv2/core/core.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [.build_release/src/caffe/layer.o] Error 1
make: *** Waiting for unfinished jobs....
make: *** [.build_release/src/caffe/data_reader.o] Error 1
make: *** [.build_release/src/caffe/internal_thread.o] Error 1
make: *** [.build_release/src/caffe/data_transformer.o] Error 1
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/filler.hpp:10,
from src/caffe/layers/dummy_data_layer.cpp:3:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/layers/concat_layer.hpp:6,
from src/caffe/layers/concat_layer.cpp:3:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/layers/log_layer.hpp:6,
from src/caffe/layers/log_layer.cpp:3:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/layer.hpp:8,
from src/caffe/layers/spatial_product_layer.cpp:4:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/layers/power_layer.hpp:6,
from src/caffe/layers/power_layer.cpp:3:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/layer.hpp:8,
from src/caffe/layers/densecrf_layer.cpp:5:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/layer.hpp:8,
from src/caffe/layer_factory.cpp:8:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [.build_release/src/caffe/layers/dummy_data_layer.o] Error 1
make: *** [.build_release/src/caffe/layers/concat_layer.o] Error 1
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/layers/im2col_layer.hpp:6,
from src/caffe/layers/im2col_layer.cpp:3:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [.build_release/src/caffe/layers/log_layer.o] Error 1
make: *** [.build_release/src/caffe/layers/spatial_product_layer.o] Error 1
make: *** [.build_release/src/caffe/layers/power_layer.o] Error 1
make: *** [.build_release/src/caffe/layers/densecrf_layer.o] Error 1
make: *** [.build_release/src/caffe/layer_factory.o] Error 1
make: *** [.build_release/src/caffe/layers/im2col_layer.o] Error 1
In file included from ./include/caffe/blob.hpp:8,
from ./include/caffe/layers/multinomial_logistic_loss_layer.hpp:6,
from src/caffe/layers/multinomial_logistic_loss_layer.cpp:5:
./include/caffe/common.hpp:4:10: fatal error: boost/shared_ptr.hpp: No such file or directory
4 | #include <boost/shared_ptr.hpp>
| ^~~~~~~~~~~~~~~~~~~~~~
compilation terminated.
make: *** [.build_release/src/caffe/layers/multinomial_logistic_loss_layer.o] Error 1

Can anyone 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.