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 argparse | |
import fnmatch | |
import json | |
import os | |
import re | |
import sys | |
from collections import namedtuple | |
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 bisect | |
from operator import itemgetter | |
units = [ | |
(1e-24, 'y'), | |
(1e-21, 'z'), | |
(1e-18, 'a'), | |
(1e-15, 'f'), | |
(1e-12, 'p'), |
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 | |
import json | |
import numpy | |
import re | |
import sys | |
from operator import itemgetter, attrgetter | |
from colormath.color_objects import sRGBColor, LabColor | |
from colormath.color_conversions import convert_color | |
from colormath.color_diff import delta_e_cie2000 |
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
#include <iostream> | |
#include <fstream> | |
#include <string> | |
#include <opencv2/imgcodecs.hpp> | |
#include <opencv2/opencv_modules.hpp> | |
#include <opencv2/stitching.hpp> | |
#include <opencv2/stitching/detail/warpers.hpp> | |
using namespace std; |
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 Foundation | |
let pixels: [[UInt8]] = [ | |
[ | |
0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, 0xFF, | |
0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, | |
0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, | |
0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, | |
0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, | |
0xFF, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xFF, |
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
protocol SomeProtocol { | |
var a: Int { get } | |
} | |
struct SomeStruct: SomeProtocol { | |
var a = 0 | |
} | |
class SomeClass { | |
var value: SomeProtocol = SomeStruct() { |
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
func test<T>(#something: T) -> T { | |
return ("abc" as? T) ?? something | |
} | |
let str: String? = "abc" | |
println(test(something: "") == str) // false | |
println(test(something: "")) // "abc" |
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
$ xcodebuild -workspace 'Test.xcworkspace' -scheme 'Test' -configuration 'Debug' -sdk iphonesimulator -destination 'name=iPhone 6' build | |
Build settings from command line: | |
SDKROOT = iphonesimulator8.3 | |
2015-02-10 09:54:05.827 xcodebuild[42416:3126221] DVTAssertions: Warning in /SourceCache/DVTiOSFrameworks/DVTiOSFrameworks-7514.1/DTDeviceKitBase/DTDKRemoteDeviceDataListener.m:79 | |
Details: Running against an old version of MobileDevice; some interaction with proxied devices may be unavailable. | |
Object: <DTDKRemoteDeviceDataListener: 0x7fcf5cf10c90> | |
Method: -listenerThreadImplementation | |
Thread: <NSThread: 0x7fcf5cf09990>{number = 2, name = (null)} | |
Please file a bug at http://bugreport.apple.com with this warning message and any useful information you can provide. |
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
PLCameraView | |
PLPreviewView | |
PLCameraFocusView | |
UIImageView | |
PLCropOverlay | |
OverlayView | |
PLCropOverlayBottomBar | |
UIImageView | |
PLCropOverlayBottomBarButton | |
UIImageView |
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
// | |
// Storage.swift | |
// | |
// Created by Martin Conte Mac Donell ([email protected]) | |
// | |
import Foundation | |
/** | |
This struct is the base for Storage Keys. This way we enforce all keys to be in a container to avoid typos |
NewerOlder