th> lyaml = require 'lyaml'
[0.0016s]
th> out = lyaml.load('key: null')
[0.0002s]
th> out.key
null
[0.0000s]
th> type(out.key)
string
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
function [C,N]=DataPerVeh(dt,VehId,Activity,cons) | |
%VehId | |
%dt=10 | |
%Activity | |
%cons=[145.83; 163.7 ;223.62; 138.3] | |
ActivityId=find((Activity{2:end,1}==VehId)); | |
VehActivity=Activity(ActivityId+1,:); | |
Nt=round(24/dt); | |
N=zeros(1,Nt); | |
C=zeros(1,Nt);%W |
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
#!/bin/bash | |
# Script for installing tmux on systems where you don't have root access. | |
# tmux will be installed in $HOME/local/bin. | |
# It's assumed that wget and a C/C++ compiler are installed. | |
# exit on error | |
set -e | |
TMUX_VERSION=2.0 |
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
# This script installs (or at least, attempts to install) Caffe in CPU mode | |
# with Python bindings without root permission. In doing so, it installs the | |
# following dependencies: | |
# | |
# * protobuf | |
# * cmake | |
# * gflags | |
# * glog | |
# * opencv | |
# * hdf5 |
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
"""Dump features calculated from a network using Caffe. | |
Run 'python frame_features.py --help' for usage information. | |
""" | |
import argparse | |
import csv | |
import errno | |
import logging | |
import numpy as np |
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 logging | |
import random | |
import os | |
import lmdb | |
from tqdm import tqdm | |
logging.getLogger().setLevel(logging.INFO) | |
logging.basicConfig(format='%(asctime)s.%(msecs).03d: %(message)s', |
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
#!/bin/bash | |
# Save current git diff, log, status to output directory. | |
# | |
# Example usage: | |
# ./dump_git_info.sh /path/to/output/directory/ | |
# ./dump_git_info.sh /path/to/output/directory/ /path/to/git/repo/ | |
# | |
# Writes the following files to output_dir: | |
# | |
# git-status.txt: Output of git status -sb. |
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
-- Exhibits differences between torch's image.scale and opencv's resize | |
-- function. | |
local cv = require 'cv' -- https://github.com/VisionLabs/torch-opencv | |
require 'cv.imgcodecs' | |
require 'cv.imgproc' | |
require 'image' | |
local path = './foobar.png' | |
-- RGB, shape channels * height * width |
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
--- test_01.lst 2016-09-09 09:31:06.640048422 -0400 | |
+++ test_01_filtered.lst 2016-09-09 16:04:00.939637895 -0400 | |
@@ -526,7 +526,6 @@ | |
/data/achald/UCF101/frames_all/v_ApplyLipstick_g02_c01/ 65 1 | |
/data/achald/UCF101/frames_all/v_ApplyLipstick_g02_c01/ 81 1 | |
/data/achald/UCF101/frames_all/v_ApplyLipstick_g02_c01/ 97 1 | |
-/data/achald/UCF101/frames_all/v_ApplyLipstick_g02_c01/ 113 1 | |
/data/achald/UCF101/frames_all/v_ApplyLipstick_g02_c02/ 1 1 | |
/data/achald/UCF101/frames_all/v_ApplyLipstick_g02_c02/ 17 1 | |
/data/achald/UCF101/frames_all/v_ApplyLipstick_g02_c02/ 33 1 |
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
configure:13020: checking for yaml.h | |
configure:13020: result: yes | |
configure:13032: checking for library containing yaml_document_initialize | |
configure:13063: gcc -o conftest -g -O2 -I/home/achald/.local/yaml-0.1.7/include -L/home/achald/.local/yaml-0.1.7/lib conftest.c >&5 | |
/tmp/ccmoDgR2.o: In function `main': | |
/home/achald/scratch/lyaml/lyaml-release-v6.0/conftest.c:36: undefined reference to `yaml_document_initialize' | |
collect2: error: ld returned 1 exit status | |
configure:13063: $? = 1 | |
configure: failed program was: | |
| /* confdefs.h */ |