OrderedSet is a set-like class that also keeps inserting order like list.
Here are some test results compared with ABC-based OrderedSet:
Boost::MultiIndex-basedMy OrderedSet | ABC-based |
---|
jq '[.assets[] | { image: .asset.name, annotations: [.regions[] | { label: .tags[0], coordinates: .boundingBox | { x: .left | round, y: .top | round, width: .width | round, height: .height | round } }] }]' |
#import <Foundation/Foundation.h> | |
int main(int argc, char *argv[]) { | |
@autoreleasepool { | |
dispatch_semaphore_t lock = dispatch_semaphore_create(0); | |
dispatch_after(dispatch_time(DISPATCH_TIME_NOW, (int64_t)(2 * NSEC_PER_SEC)), dispatch_get_global_queue(QOS_CLASS_DEFAULT, 0), ^{ | |
NSLog(@"unlock"); | |
dispatch_semaphore_signal(lock); | |
}); |
# configure for armv7 build | |
./configure \ | |
--cc=/Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc \ | |
--as='/usr/local/bin/gas-preprocessor.pl /Developer/Platforms/iPhoneOS.platform/Developer/usr/bin/gcc' \ | |
--sysroot=/Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.3.sdk \ | |
--target-os=darwin \ | |
--arch=arm \ | |
--cpu=cortex-a8 \ | |
--extra-cflags='-arch armv7' \ | |
--extra-ldflags='-arch armv7 -isysroot /Developer/Platforms/iPhoneOS.platform/Developer/SDKs/iPhoneOS4.3.sdk' \ |
OrderedSet is a set-like class that also keeps inserting order like list.
Here are some test results compared with ABC-based OrderedSet:
Boost::MultiIndex-basedMy OrderedSet | ABC-based |
---|
iftgen.py
5 Seconds of Summer.txt
and 5 Seconds of Summer.ac3.txt
will be generated5 Seconds of Summer.txt
and combine them with cat *.ts > combined.ts
5 Seconds of Summer.ac3.txt
and combine them with cat *.ac3 > combined.ac3
# Copyright (C) 2008 Apple Inc. All Rights Reserved. | |
# Copyright (C) 2013 Grey Lee. All Rights Reserved. | |
# | |
# Redistribution and use in source and binary forms, with or without | |
# modification, are permitted provided that the following conditions are met: | |
# | |
# 1. Redistributions of source code must retain the above copyright notice, this | |
# list of conditions and the following disclaimer. | |
# 2. Redistributions in binary form must reproduce the above copyright notice, | |
# this list of conditions and the following disclaimer in the documentation |
#!/usr/bin/env python | |
import datetime | |
import glob | |
import os | |
import re | |
import sys | |
def main(base_path): | |
msgid = set() |
txt = u'\U0001f600' | |
r = re.compile(u'[\uD800-\uDBFF][\uDC00-\uDFFF]') | |
r.sub('', txt) |