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

how can I get boxes when run yolov2_tiny-face.h5 #12

Open
KienPM opened this issue Dec 12, 2019 · 1 comment
Open

how can I get boxes when run yolov2_tiny-face.h5 #12

KienPM opened this issue Dec 12, 2019 · 1 comment

Comments

@KienPM
Copy link

KienPM commented Dec 12, 2019

Hello, I'm a newbie
I want to gets boxes from yolov2_tiny-face.h5. Here is my code

from keras.models import load_model
from PIL import Image, ImageDraw
import numpy as np

input_image = Image.open('test.jpg')
image = input_image.resize((416, 416))
image = np.array(image)
image = image / 255.
image = np.expand_dims(image, 0)

model = load_model('yolov2_tiny-face.h5')
model.summary()
outputs = model.predict(image)

I got outputs.shape = (1, 13, 13, 30), same as last layer's shape, seem not correct
Could you help me please!

@Javcm
Copy link

Javcm commented Mar 21, 2021

Hey, could you solve this? I have the same issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants