Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update README.md #427

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,12 @@ $ cd ..
$ python convert_weight.py
$ python freeze_graph.py
```
4. Then you will get some `.pb` files in the root path., and run the demo script
4. If you want to get darknet-yolov3 [weights](https://pjreddie.com/darknet/yolo/) work in this project,run the following scripts to convert it.
```bashrc
$ python from_darknet_weights_to_ckpt.py # If you just want pb files, skip to the next line.
$ python from_darknet_weights_to_pb.py
```
5. Then you will get some `.pb` files in the root path., and run the demo script
```bashrc
$ python image_demo.py
$ python video_demo.py # if use camera, set video_path = 0
Expand Down
4 changes: 2 additions & 2 deletions core/dataset.py
Original file line number Diff line number Diff line change
Expand Up @@ -119,8 +119,8 @@ def random_crop(self, image, bboxes):

crop_xmin = max(0, int(max_bbox[0] - random.uniform(0, max_l_trans)))
crop_ymin = max(0, int(max_bbox[1] - random.uniform(0, max_u_trans)))
crop_xmax = max(w, int(max_bbox[2] + random.uniform(0, max_r_trans)))
crop_ymax = max(h, int(max_bbox[3] + random.uniform(0, max_d_trans)))
crop_xmax = min(w, int(max_bbox[2] + random.uniform(0, max_r_trans)))
crop_ymax = min(h, int(max_bbox[3] + random.uniform(0, max_d_trans)))

image = image[crop_ymin : crop_ymax, crop_xmin : crop_xmax]

Expand Down