This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
table tr:nth-child(13) td:first-child{ | |
background-color: green; | |
color: white; | |
} |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
f1 = open('log.txt','r') | |
f2 = open('parsedLog.txt','w') | |
for l in f1: | |
if 'eduroam' in l: | |
f2.write(l) | |
print(l) | |
f1.close() | |
f2.close() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import copy | |
print("Copy List Reference:") | |
a = [1, 2, 3] | |
b = a | |
b[0] = 42 | |
print('{}\n{}'.format(a, b)) | |
print("Copy List Elements") | |
a = [1, 2, 3] |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
import paho.mqtt.client as mqttClient | |
import MySQLdb as mdb | |
import time | |
#broker_address= "m11.cloudmqtt.com" #Broker address | |
broker_address = "localhost" | |
broker_port = 1883 #Broker broker_port | |
#broker_user = "yourUser" #Connection username | |
#broker_password = "yourPassword" #Connection password |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
db_hostname = "localhost" # MySQL host ip address or name | |
db_database = "mqtt" # MySQL database name | |
db_username = "mqttuser" # MySQL database user name | |
db_password = "mqttpass" # MySQL database password | |
import MySQLdb as mdb | |
import time |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python | |
import paho.mqtt.client as mqttClient | |
import time | |
def on_connect(client, userdata, flags, rc): | |
if rc == 0: | |
print("Connected to broker") | |
global Connected #Use global variable | |
Connected = True #Signal connection | |
else: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
wget -nc https://download.sublimetext.com/Sublime%20Text%202.0.2%20x64.tar.bz2 -P ~/Downloads/ | |
mkdir -p ~/Downloads/sublime | |
tar -xjf ~/Downloads/Sublime\ Text\ 2.0.2\ x64.tar.bz2 --directory ~/Downloads/sublime --strip-components 1 | |
cd ~/Downloads/sublime | |
ln -sf sublime_text subl | |
PATH=$PATH:$HOME/Downloads/sublime | |
nohup ./sublime_text & |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import cv2 | |
import cv2.aruco as aruco | |
cap = cv2.VideoCapture(0) | |
while(True): | |
# Capture frame-by-frame | |
ret, frame = cap.read() |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
import cv2 | |
cap = cv2.VideoCapture(0) | |
#dictionary = cv2.aruco.getPredefinedDictionary(cv2.aruco.DICT_5X5_1000) | |
#dictionary = cv2.aruco.getPredefinedDictionary(cv2.aruco.DICT_4X4_50) | |
dictionary = cv2.aruco.getPredefinedDictionary(cv2.aruco.DICT_ARUCO_ORIGINAL) | |
while(True): | |
# Capture frame-by-frame |