This file contains 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
export LD_LIBRARY_PATH=/usr/local/lib:${LD_LIBRARY_PATH} | |
#path to bin directory with libANN_char.so, Approximate Nearest Neighbor library | |
export LD_LIBRARY_PATH=./bin/ |
This file contains 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
#Not mentioned after following mapbox.com/mapbox- ios-sdk, go to Targets > Build Settings > Search Paths > User Header Search Paths | |
$(SCROOT)/path/to/mapbox.framework | |
#select 'recursive' |
This file contains 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
NSURL *theURL = [NSURL URLWithString:@"yourURL"]; | |
NSMutableURLRequest *theRequest = [NSMutableURLRequest requestWithURL:theURL cachePolicy:NSURLRequestReloadIgnoringCacheData timeoutInterval:20.0f]; | |
//Specify method of request(Get or Post) | |
[theRequest setHTTPMethod:@"GET"]; | |
//Pass some default parameter(like content-type etc.) | |
[theRequest setValue:@"application/json" forHTTPHeaderField:@"Accept"]; | |
[theRequest setValue:@"application/json; charset=UTF-8" forHTTPHeaderField:@"Content-Type"]; |
This file contains 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
mount -o remount, rw / |
This file contains 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
Add the --no-x-check flag in terminal: | |
sudo ./NVIDIAxxxx.run --no-x-check |
This file contains 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
url = 'https://farm4.staticflickr.com/3943/15386021170_c2607cb639_z.jpg' | |
#\d+ match digits; \D+ match a non-digit which is "/" after the 1st 4 digits; (d\+) get the last set of digits, in group(6) | |
re.search(r'^(https://)?(farm4\.)?(staticflickr\.com/)?(\d+)?(\D+)(\d+)',url).group(6) | |
#returns 15386021170 |
This file contains 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
sudo mount /dev/sdb1 /mnt |
This file contains 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
g++ -o test_1 test_1.cpp `pkg-config opencv --cflags --libs` |
This file contains 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 cv2 | |
>>> flags = [i for i in dir(cv2) if i.startswith('COLOR_')] | |
>>> print flags |
This file contains 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
lsusb -v 2> /dev/null | grep -e "Apple Inc" -A 2 |
OlderNewer