Skip to content

Instantly share code, notes, and snippets.

View shssoichiro's full-sized avatar

Josh Holmer shssoichiro

  • United States
View GitHub Profile
@shssoichiro
shssoichiro / main.rs
Last active November 28, 2015 06:02
242 Hard
extern crate rand;
use std::cmp;
use std::env;
use std::fmt;
use rand::{thread_rng, Rng};
#[derive(PartialEq,Clone)]
enum Colors {
Black,
@shssoichiro
shssoichiro / main.rs
Last active December 4, 2015 17:19
Daily Challenge 243 Hard (Part 1)
extern crate petgraph;
use std::env;
use std::fs::File;
use std::io::prelude::*;
use std::io::BufReader;
use std::collections::HashMap;
use petgraph::graph;
fn main() {
@shssoichiro
shssoichiro / lib.rs
Last active February 15, 2016 15:23
#![feature(test)]
extern crate test;
#[cfg(test)]
mod tests {
use test::Bencher;
#[bench]
fn bench_split_short_str(b: &mut Bencher) {
#![feature(test)]
extern crate test;
#[cfg(test)]
mod tests {
use test::Bencher;
#[bench]
fn bench_split_short_str(b: &mut Bencher) {

Version Versioning v2016.03

Summary

The version format of your project changes arbitrarily.

Introduction

As you manage a software product, you will have many choices on how to manage the versions of it. Most versioning systems have the following problems:

impl<C: Connection> Connection for LoggingConnection<C>
where
C: Connection<TransactionManager = AnsiTransactionManager> + Send + 'static,
C::Backend: UsesAnsiSavepointSyntax,
{
type Backend = C::Backend;
fn query_by_index<T, U>(&self, source: T) -> QueryResult<Vec<U>>
where
T: AsQuery,
use bitstream_io::{BigEndian, BitWriter};
use std::io;
use std::mem::size_of;
use uuid::Uuid;
use std::io::Write;
/// Boxes start with a header which gives both size and type.
/// The header permits compact or extended size (32 or 64 bits)
/// and compact or extended types (32 bits or full UUIDs).
/// The standard boxes all use compact types (32-bit)
@shssoichiro
shssoichiro / .zshrc
Created May 8, 2019 17:19
Powerlevel9k Docker Env Component
# Make sure to place these near the top of your .zshrc. I have them after my `export PATH` and `export ZSH`.
# They must come BEFORE your POWERLEVEL9K variables.
# This will start docker-machine when your terminal opens, if it is not already started, and then default to sourcing the docker-machine environment
[[ `docker-machine status` = "Stopped" ]] && echo "\nThe Docker virtual machine is not running.\nAttemping to start the VM. This should take about a minute.\n" && docker-machine start
eval $(docker-machine env)
# This will start minikube if it is not already started
[[ `minikube status` = *"Stopped"* ]] && echo "\nThe Minikube virtual machine is not running.\nAttemping to start the VM. This should take about a minute.\n" && minikube start
@shssoichiro
shssoichiro / edi_rpow2.py
Created October 6, 2021 21:46
edi_rpow2.py for VS R55+
def nnedi3_rpow2(clip,rfactor,correct_shift="zimg",nsize=0,nns=3,qual=None,etype=None,pscrn=None,opt=None,int16_prescreener=None,int16_predictor=None,exp=None):
import vapoursynth as vs
core = vs.core
def edi(clip,field,dh):
return core.nnedi3.nnedi3(clip=clip,field=field,dh=dh,nsize=nsize,nns=nns,qual=qual,etype=etype,pscrn=pscrn,opt=opt,int16_prescreener=int16_prescreener,int16_predictor=int16_predictor,exp=exp)
return edi_rpow2(clip=clip,rfactor=rfactor,correct_shift=correct_shift,edi=edi)
def znedi3_rpow2(clip,rfactor,correct_shift="zimg",nsize=0,nns=3,qual=None,etype=None,pscrn=None,opt=None,int16_prescreener=None,int16_predictor=None,exp=None):
@shssoichiro
shssoichiro / settings.md
Last active March 21, 2024 22:36
aomenc settings (Updated 2022-09-18)

Current aomenc recommended settings for sharpness and detail retention:

--cpu-used=4 --cq-level=16 --end-usage=q --lag-in-frames=48 --enable-fwd-kf=1 --aq-mode=1 --deltaq-mode=0 --enable-chroma-deltaq=1 --quant-b-adapt=1 --enable-qm=1 --min-q=1 --enable-keyframe-filtering=0 --arnr-strength=1 --arnr-maxframes=4 --sharpness=3 --enable-dnl-denoising=0 --disable-trellis-quant=0 --threads=64

General CQ guidelines:

  • 40: Youtube quality
  • 30: Watchable, fine for streaming or lower bitrate encodes
  • 20: Good quality