Folder structure before (2 separate repositories):
XXX
|- .git
|- (project files)
YYY
|- .git
# This script is based on https://github.com/nvellon/timelapse | |
import os | |
import sys | |
import time | |
import cv2 | |
command = 'capture' | |
cam_num = 0 | |
output_path = 'out/' |
// Created by Thibaut Mattio | |
#pragma once | |
#include <ctime> | |
#include <random> | |
namespace random { | |
inline auto random_float(float min = 0., float max = 1.) { |
#pragma once | |
#include <atomic> | |
#include <condition_variable> | |
/// A mutex guaranted noexcept that can be used in destructors. | |
/// See: | |
/// http://stackoverflow.com/questions/16568990/locking-a-mutex-in-a-destructor-in-c11 | |
template <class Tp_ = std::mutex> | |
class nothrow_mutex { | |
public: |
#include <gtest/gtest.h> | |
#include <tbb/flow_graph.h> | |
#include <opencv2/core.hpp> | |
using namespace tbb::flow; | |
/** | |
* Simple functor that return the inverted matrix. | |
*/ | |
struct pass_image { |
#include <Python.h> | |
#include <opencv2/core/core.hpp> | |
#include <numpy/ndarrayobject.h> | |
#include <cstdio> | |
using namespace cv; | |
static PyObject* opencv_error = 0; | |
#define ERRWRAP2(expr) \ |
import sys | |
import re | |
def list_interfaces(input_file): | |
with open(input_file) as fp: | |
lines = fp.read().splitlines() | |
for l in lines: | |
match = re.match(r'^Interface (.*)$', l) |
defmodule CreateCat do | |
use Ecto.Migration | |
def change do | |
create table(:cats) do | |
end | |
end | |
end | |
defmodule CreateDog do |
import sys | |
import json | |
import csv | |
def truncate(s: str, threshold: int = 120): | |
return (s[:threshold] + "..") if len(s) > threshold else s | |
def get_headers(): |