Skip to content

Instantly share code, notes, and snippets.

@sorashido
sorashido / editor.css
Last active November 9, 2018 02:31
quiver theme
/*
Edit this CSS file to change styles of the editor.
If you need to revert it back, use the "Reset" button.
*/
/**
* Text Cell
*/
.text-cell {
@sorashido
sorashido / Makefile
Last active October 6, 2018 17:23
pytorch-dockerfile
help:
@cat Makefile
NAME="pytorch"
SRC?="$(shell pwd)/:/app" #src directory
DOCKER=GPU=$(GPU) nvidia-docker
bash:
$(DOCKER) run -it -v $(SRC) --name $(NAME) -p 8080:8080 anibali/pytorch:cuda-9.0 bash
/* スコープを与える */
var SlackDelFileApp = {}
/* SLACKのTOKENを読み込み */
SlackDelFileApp.SLACK_ACCESS_TOKEN = PropertiesService.getScriptProperties().getProperty('SLACK_ACCESS_TOKEN');// slackで発行したTOKENをGASの環境変数に設定
/* soundTricker/SlackApp を使うよりurlからAPI叩いたほうが早いらしいので */
SlackDelFileApp.execute = function(method, params){
if (params === undefined ) params = {'token' : SlackDelFileApp.SLACK_ACCESS_TOKEN};
var options = {
from TwitterAPI import TwitterAPI, TwitterPager
import csv
SCREEN_NAME = 'McDonaldsJapan'
CONSUMER_KEY = 'xxx'
CONSUMER_SECRET = 'xxxxxx'
api = TwitterAPI(CONSUMER_KEY,
CONSUMER_SECRET,
auth_type='oAuth2')
@sorashido
sorashido / imageServer.go
Created June 11, 2018 06:48
very simple image server
package main
import (
"net/http"
"fmt"
"github.com/gin-gonic/gin"
"github.com/olahol/go-imageupload"
"time"
)
# .zshrc file
export PATH=/usr/local/bin:/usr/bin:/bin:/sbin:/usr/sbin
export TERM=xterm-256color
# HISTORY
HISTFILE=~/.dotfiles/zsh/.zsh_history
HISTSIZE=1000000
SAVEHIST=1000000
# LANG設定 rootの場合はCに設定

grade3

jt -t grade3 -fs 95 -altp -tfs 11 -nfs 115 -cellw 88% -T -N

onedork

jt -t onedork -fs 95 -altp -tfs 11 -nfs 115 -cellw 88% -T -N

function sendMessage(text){
var postUrl = 'URL';
var username = 'bot';
var icon = ':hatched_chick:';
var message = text;
var jsonData = {
"username" : username,
"icon_emoji": icon,
@sorashido
sorashido / CMakeLists.txt
Last active June 5, 2021 09:04
opencv3_multitracking_sample
cmake_minimum_required(VERSION 2.8)
project(sample)
add_executable(pedestrian
main.cpp
# kalman.cpp
)
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -W -Wall")
set (CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -std=c++11")
## エージェント配置の画像化
source("./scripts/const.R")
library(GGally)
library(network)
library(sna)
library(ggplot2)
library(igraph)