You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This repository is modified from Caffe version of [yjxiong](https://github.com/yjxiong/caffe/tree/mem) and [DeepLab v2](https://bitbucket.org/aquariusjay/deeplab-public-ver2) for testing. Results are tested on Ubuntu 14.04. Trainable code will be available later.
7
+
This repository is modified from Caffe version of [yjxiong](https://github.com/yjxiong/caffe/tree/mem) and [DeepLab v2](https://bitbucket.org/aquariusjay/deeplab-public-ver2) for evaluation. We merge the batch normalization layer named 'bn_layer' in the former one into the later one while keep the original 'batch_norm_layer' in the later one unchanged for compatibility. The difference is that 'bn_layer' contains four parameters as 'slope,bias,mean,variance' while 'batch_norm_layer' contains two parameters as 'mean,variance'. Several evaluation code is borrowed from [MIT Scene Parsing](https://github.com/CSAILVision/sceneparsing).
8
+
9
+
## Installation
10
+
11
+
For installation, please follow the instructions of [Caffe](https://github.com/BVLC/caffe) and [DeepLab v2](https://bitbucket.org/aquariusjay/deeplab-public-ver2). To enable cuDNN for GPU acceleration, cuDNN v5 is needed as required in 'yjxiong'. If you meet error related with 'matio', please please download and install [matio](matio) as required in 'DeepLab v2'.
12
+
13
+
The code has been tested successfully on Ubuntu 14.04 and 12.04 with CUDA 7.0.
8
14
9
15
### Usage
10
16
@@ -14,44 +20,67 @@ This repository is modified from Caffe version of [yjxiong](https://github.com/y
14
20
git clone https://github.com/hszhao/PSPNet.git
15
21
```
16
22
17
-
2. Build Caffe and matcaffe
23
+
2. Build Caffe and matcaffe:
18
24
19
25
```shell
20
26
cd$PSPNET_ROOT
27
+
cp Makefile.config.example Makefile.config
28
+
vim Makefile.config
21
29
make -j8 && make matcaffe
22
30
```
23
31
24
-
3. Testing
25
-
26
-
Evaluation code is in folder 'evaluation'.
27
-
28
-
Download trained models and put it in folder 'evaluation/model/':
- Mainly variables 'data_root' and 'eval_list', and your image list for evaluation should be similarity to that in folder 'evaluation/samplelist' if you use this evaluation code structure.
41
+
- Matlab 'parfor' evaluation is used and the default GPUs are with ID [0:3]. Modify variable 'gpu_id_array' if needed. We assume that number of images can be divided by number of GPUs; if not, you can just pad your image list or switch to single GPU evaluation by set 'gpu_id_array' be length of one, and change 'parfor' to 'for' loop.
37
42
38
43
```shell
39
44
cd evaluation
40
45
vim eval_all.m
41
46
```
42
47
43
-
Run the testing scripts:
48
+
-Run the evaluation scripts:
44
49
45
50
```
46
51
./run.sh
47
52
```
48
53
49
-
4. Results: (single scale testing denotes as 'ss' and multiple scale testing denotes as 'ms')
54
+
4. Results:
55
+
56
+
Prediction results will show in folder 'evaluation/mc_result' and the expected scores are:
57
+
58
+
(single scale testing denotes as 'ss' and multiple scale testing denotes as 'ms')
50
59
51
60
- PSPNet50 on ADE20K valset (mIoU/pAcc): 41.68/80.04 (ss) and 42.78/80.76 (ms)
52
61
- PSPNet101 on VOC2012 testset (mIoU): 85.41 (ms)
53
62
- PSPNet101 on cityscapes valset (mIoU/pAcc): 79.70/96.38 (ss) and 80.91/96.59 (ms)
54
63
64
+
5. Demo video:
65
+
66
+
Video processed by PSPNet101 on cityscapes dataset: [Youtube](https://youtu.be/gdAVqJn_J2M)
67
+
68
+
## Citation
69
+
70
+
If PSPNet is useful for your research, please consider citing:
0 commit comments