In your command-line run the following commands:
brew doctorbrew update
In your command-line run the following commands:
brew doctorbrew update| from sklearn.cluster import KMeans | |
| from sklearn import metrics | |
| import cv2 | |
| # By Adrian Rosebrock | |
| import numpy as np | |
| import cv2 | |
| # Load the image | |
| image = cv2.imread("red.png") |
| #!/usr/bin/env php | |
| <?php | |
| /* | |
| * Filter to fill the IP gaps in a MaxMind GeoLite tables. | |
| * | |
| * For every missing range in the file it puts a dummy one. | |
| */ | |
| $types = [ | |
| 'asnum' => [0, 0, 1, "%s,%s,\"-\"\n"], | |
| 'blocks' => [2, 0, 1, "\"%s\",\"%s\",\"1\"\n"], |
| import pymssql | |
| import pandas as pd | |
| ## instance a python db connection object- same form as psycopg2/python-mysql drivers also | |
| conn = pymssql.connect(server="172.0.0.1", user="howens",password="some_fake_password", port=63642) # You can lookup the port number inside SQL server. | |
| ## Hey Look, college data | |
| stmt = "SELECT * FROM AlumniMirror..someTable" | |
| # Excute Query here | |
| df = pd.read_sql(stmt,conn) |
| # post_loc.txt contains the json you want to post | |
| # -p means to POST it | |
| # -H adds an Auth header (could be Basic or Token) | |
| # -T sets the Content-Type | |
| # -c is concurrent clients | |
| # -n is the number of requests to run in the test | |
| ab -p post_loc.txt -T application/json -H 'Authorization: Token abcd1234' -c 10 -n 2000 http://example.com/api/v1/locations/ |