Skip to content

Instantly share code, notes, and snippets.

View yusuketomoto's full-sized avatar

Yusuke Tomoto yusuketomoto

  • San Francisco, CA.
View GitHub Profile
@usrlocalben
usrlocalben / stackblur.cpp
Created October 1, 2012 02:24
stackblur - c++, floating-point, vectorized
/*
* "stackblur"
* originally, Mario Klingemann, [email protected]
* this implementation, Benjamin Yates ([email protected])
* http://incubator.quasimondo.com/processing/stackblur.pde
*
* this blur routine seems to be quite popular.
*
* unfortunately, mario didn't comment anything.
* but, it's easy to see it's just a flavor of a two-pass
@rezoo
rezoo / numpy.hpp
Last active April 14, 2024 17:37
Reimplementation of libnpy. This library is header-only and compatible with any environment including MSVC.
/*
* Copyright (c) 2012 Masaki Saito
*
* Permission is hereby granted, free of charge, to any person obtaining a copy
* of this software and associated documentation files (the "Software"), to deal
* in the Software without restriction, including without limitation the rights
* to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
* copies of the Software, and to permit persons to whom the Software is
* furnished to do so, subject to the following conditions:
*
@zenorocha
zenorocha / .hyper.js
Last active November 12, 2023 15:13 — forked from millermedeiros/osx_setup.md
Setup macOS Sierra (10.12)
// Future versions of Hyper may add additional config options,
// which will not automatically be merged into this file.
// See https://hyper.is#cfg for all currently supported options.
module.exports = {
config: {
// default font size in pixels for all tabs
fontSize: 14,
// font family with optional fallbacks
@satoruhiga
satoruhiga / .clang-format
Last active August 29, 2015 13:56
.clang-format setting
BasedOnStyle: Google
Standard: Cpp03
# BreakBeforeBraces: Allman
PointerBindsToType: true
DerivePointerBinding: false
# tab
UseTab: Always
TabWidth: 4
@satoruhiga
satoruhiga / CollectAllWindows.applescript
Created December 28, 2014 11:46
collect all windows
(*
collect all windows
http://apple.stackexchange.com/questions/709/how-to-retrieve-windows-that-have-moved-off-screen
http://d.hatena.ne.jp/hirose31/20111213/1323761962
*)
property processesToIgnore : {}
tell (do shell script "/usr/sbin/system_profiler SPDisplaysDataType | grep Resolution | tail -n 1") to set {screen_width, screen_height} to {word 2, word 4}
@satoruhiga
satoruhiga / stack_blur.h
Last active April 3, 2016 14:43
stack_blur.h
#include "ofMain.h"
namespace stack_blur {
template<class T> struct stack_blur_tables {
static uint16_t const g_stack_blur8_mul[255];
static uint8_t const g_stack_blur8_shr[255];
};
//------------------------------------------------------------------------
#!/usr/bin/env python
# -*- coding: utf-8 -*-
# this is a quick implementation of http://arxiv.org/abs/1508.06576
# BUT! This is kind of dirty. Lots of hard coding. 
import numpy as np
import math
from chainer import cuda, Function, FunctionSet, gradient_check, Variable, optimizers
import chainer.functions as Fu
@2bbb
2bbb / ofApp.cpp
Created September 10, 2015 11:42
taylor
#include "ofMain.h"
double frac_table[101];
double frac(int n) {
double v = 1;
for(int i = 1; i <= n; i++) {
v *= i;
}
return v;
@Akira-Hayasaka
Akira-Hayasaka / winInst.txt
Last active September 16, 2021 07:33
windows インスタレーション用設定
- windowsはオフラインアカウントでセットアップ
- ネットワークにつなぐ
- 識別されてないネットワーク問題
http://www.projectgroup.info/tips/Windows/comm_0064.html
- windowsのライセンス認証
- windowsをアップデートする
@steipete
steipete / ios-xcode-device-support.sh
Last active October 14, 2024 16:35
Using iOS 15 devices with Xcode 12.5 (instead of Xcode 13)
# The trick is to link the DeviceSupport folder from the beta to the stable version.
# sudo needed if you run the Mac App Store version. Always download the dmg instead... you'll thank me later :)
# Support iOS 15 devices (Xcode 13.0) with Xcode 12.5:
sudo ln -s /Applications/Xcode-beta.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport/15.0 /Applications/Xcode.app/Contents/Developer/Platforms/iPhoneOS.platform/DeviceSupport
# Then restart Xcode and reconnect your devices. You will need to do that for every beta of future iOS versions
# (A similar approach works for older versions too, just change the version number after DeviceSupport)