Skip to content

Commit

Permalink
Update README.md
Browse files Browse the repository at this point in the history
 (5*2 + number_of_classes)*7*7, as an example, assuming no other parameters are modified.
  • Loading branch information
Guanghan committed Jan 6, 2016
1 parent e8215aa commit ceaf26d
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,9 @@ For questions or issues please use the [Google Group](https://groups.google.com/
(2) In [src/yolo_kernels.cu](https://github.com/Guanghan/darknet/blob/master/src/yolo_kernels.cu), change class numbers.

(3) Now we are able to train with new classes, but there is one more thing to deal with. In YOLO, the number of parameters of the second last layer is not arbitrary, instead it is defined by some other parameters including the number of classes, the side(number of splits of the whole image). Please read [the paper](http://arxiv.org/abs/1506.02640)


(5*2 + number_of_classes)*7*7, as an example, assuming no other parameters are modified.

Therefore, in [cfg/yolo.cfg](https://github.com/Guanghan/darknet/blob/master/cfg/yolo.cfg), change the "output" in line 218, and "classes" in line 222.

(4) Now we are good to go. If we need to change the number of layers and experiment with various parameters, just mess with the cfg file. For the original yolo configuration, we have the [pre-trained weights](http://pjreddie.com/media/files/extraction.conv.weights) to start from. For arbitrary configuration, I'm afraid we have to generate pre-trained model ourselves.
Expand Down

0 comments on commit ceaf26d

Please sign in to comment.