Skip to content

Instantly share code, notes, and snippets.

@arunm8489
Created June 5, 2020 15:31
Show Gist options
  • Save arunm8489/85f97155b308a2e93449e3b235b6c9df to your computer and use it in GitHub Desktop.
Save arunm8489/85f97155b308a2e93449e3b235b6c9df to your computer and use it in GitHub Desktop.
CUDA = False
image_name = "dog-cycle-car.png"
nms_thesh = 0.5
#Set up the neural network
print("Loading network.....")
model = Darknet(cfgfile)
model.load_weights(weightsfile)
print("Network successfully loaded")
classes = load_classes(classfile)
print('Classes loaded')
conf_inp_dim = int(model.net_info["height"])#608
# treading and resizing image
processed_image, original_image, original_img_dim = preprocess_image(image_name,conf_inp_dim)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment