update readme

This commit is contained in:
Dimitrii
2019-04-16 09:53:21 +03:00
parent 9164d6b47a
commit 3ce62c7a6f
3 changed files with 22 additions and 4 deletions

4
.gitignore vendored
View File

@@ -4,3 +4,7 @@ example/coco.data
example/coco.names
example/yolov3-320.cfg
example/yolov3-320.weights
example/yolov3-416.cfg
example/yolov3-416.weights
example/yolov3.cfg
example/yolov3.weights

View File

@@ -48,9 +48,23 @@ cd $GOPATH/github.com/LdDl/go-darknet/example
#build program
go build main.go
#run it
./main -configFile yolov3-320.cfg --dataConfigFile coco.data -imageFile sample.jpg -weightsFile yolov3-320.weights
./main -configFile yolov3.cfg --dataConfigFile coco.data -imageFile sample.jpg -weightsFile yolov3.weights
```
Output should be something like this:
```shell
truck (7): 95.6232% | start point: (78,69) | end point: (222, 291)
truck (7): 81.5451% | start point: (0,114) | end point: (90, 329)
car (2): 99.8129% | start point: (269,192) | end point: (421, 323)
car (2): 99.6615% | start point: (567,188) | end point: (743, 329)
car (2): 99.5795% | start point: (425,196) | end point: (544, 309)
car (2): 96.5765% | start point: (678,185) | end point: (797, 320)
car (2): 91.5156% | start point: (391,209) | end point: (441, 291)
car (2): 88.1737% | start point: (507,193) | end point: (660, 324)
car (2): 83.6209% | start point: (71,199) | end point: (102, 281)
bicycle (1): 59.4000% | start point: (183,276) | end point: (257, 407)
person (0): 96.3393% | start point: (142,119) | end point: (285, 356)
```
## Documentation
See go-darknet's API documentation at [GoDoc].

View File

@@ -2,5 +2,5 @@ wget --output-document=sample.jpg https://cdn-images-1.medium.com/max/800/1*EYFe
wget --output-document=coco.names https://raw.githubusercontent.com/pjreddie/darknet/master/data/coco.names
wget --output-document=coco.data https://raw.githubusercontent.com/pjreddie/darknet/master/cfg/coco.data
sed -i 's#data/coco.names#coco.names#g' coco.data
wget --output-document=yolov3-320.cfg https://raw.githubusercontent.com/pjreddie/darknet/master/cfg/yolov3.cfg
wget --output-document=yolov3-320.weights https://pjreddie.com/media/files/yolov3.weights
wget --output-document=yolov3.cfg https://raw.githubusercontent.com/pjreddie/darknet/master/cfg/yolov3.cfg
wget --output-document=yolov3.weights https://pjreddie.com/media/files/yolov3.weights