<commit_before>#########################################################
#
# DO NOT EDIT THIS FILE. IT IS GENERATED AUTOMATICALLY. #
# PLEASE LOOK INTO THE README FOR MORE INFORMATION.     #
#
#########################################################


# coding: utf-8

# # Loading Pre-Trained Models
# 
# In this tutorial, we'll use the `squeezenet` model to identify objects in images. The image location will pass in a URL to a photo or the location of a local file. The codes is a list of [AlexNet object codes](https://gist.githubusercontent.com/aaronmarkham/cd3a6b6ac071eca6f7b4a6e40e6038aa/raw/9edb4038a37da6b5a44c3b5bc52e448ff09bfe5b/alexnet_codes), like "985" which equates to "daisy".
# 
# If you came from the Image Pre-Processing Tutorial, you will see that we're using rescale and crop functions to prep the image, as well as reformatting the image to be CHW, BGR, and finally NCHW. We also correct the image mean, by either using the calculated mean from a provided npy file or statically removing 128 as a placeholder average.
# 
# You'll find that loading pre-trained model is really simple and is accomplished in just a few lines of code. Here we show those few lines:
# 
# 1. read the protobuf files
# 
#         with open("init_net.pb") as f:
#             init_net = f.read()
#         with open("predict_net.pb") as f:
#             predict_net = f.read()        
# 
# 2. use the Predictor function in your workspace to load the blobs from the protobufs
# 
#         p = workspace.Predictor(init_net, predict_net)
# 
# 3. run the net and get the results!
# 
#         results = p.run({'data': img})
# 
# The results come back as a multidimensional array of probabilities. Essentially each row is a percentage chance that the object matches something that the neural net recognizes. When you run the flower it should give you over 95% rating that the flower is a daisy.
# 
# ## Configuration 
# 
# Settings are in a code block below. Most of the time these should run out of the box. <commit_msg>Fix test failure with tutorials.<commit_after>#########################################################
#
# DO NOT EDIT THIS FILE. IT IS GENERATED AUTOMATICALLY. #
# PLEASE LOOK INTO THE README FOR MORE INFORMATION.     #
#
#########################################################


# coding: utf-8

# # Loading Pre-Trained Models
# 
# In this tutorial, we'll use the `squeezenet` model to identify objects in images. The image location will pass in a URL to a photo or the location of a local file. The codes is a list of [ImageNet object codes](https://gist.githubusercontent.com/aaronmarkham/cd3a6b6ac071eca6f7b4a6e40e6038aa/raw/9edb4038a37da6b5a44c3b5bc52e448ff09bfe5b/alexnet_codes), like "985" which equates to "daisy".
# 
# If you came from the Image Pre-Processing Tutorial, you will see that we're using rescale and crop functions to prep the image, as well as reformatting the image to be CHW, BGR, and finally NCHW. We also correct the image mean, by either using the calculated mean from a provided npy file or statically removing 128 as a placeholder average.
# 
# You'll find that loading pre-trained model is really simple and is accomplished in just a few lines of code. Here we show those few lines:
# 
# 1. read the protobuf files
# 
#         with open("init_net.pb") as f:
#             init_net = f.read()
#         with open("predict_net.pb") as f:
#             predict_net = f.read()        
# 
# 2. use the Predictor function in your workspace to load the blobs from the protobufs
# 
#         p = workspace.Predictor(init_net, predict_net)
# 
# 3. run the net and get the results!
# 
#         results = p.run({'data': img})
# 
# The results come back as a multidimensional array of probabilities. Essentially each row is a percentage chance that the object matches something that the neural net recognizes. When you run the flower it should give you over 95% rating that the flower is a daisy.
# 
# ## Configuration 
# 
# Settings are in a code block below. Most of the time these should run out of the box. 
{'fraction_non_alphanumeric': 0.12068114511352418, 'fraction_numerical': 0.02418558736426456, 'mean_word_length': 3.7237762237762237, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 2, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '7485275', 'n_tokens_mistral': 1245, 'n_tokens_neox': 1151, 'n_words': 532}