This file contains hidden or 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
https://www.amazon.co.jp/我々はなぜ我々だけなのか-アジアから消えた多様な「人類」たち-ブルーバックス-川端-裕人/dp/4065020379/ref=tmm_pap_swatch_0?_encoding=UTF8&qid=&sr= | |
ジャワ原人 | |
ホモ・エレクトス | |
現生人類に近い | |
120万年前にはジャワ島にいた | |
5万年前まではいた | |
ホモ・サピエンスがユーラシアにいる | |
4万7000年前までにはオーストラリア大陸に到達してる | |
アジアの人 |
This file contains hidden or 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
require 'benchmark' | |
require "committee" | |
COUNT = 10000 | |
noop = Proc.new {[200, {}, ["hello"]]} | |
middleware = Committee::Middleware::RequestValidation.new(noop, schema_path: 'demo.yaml') | |
# warmup | |
request = Rack::MockRequest.new(middleware) |
This file contains hidden or 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
# frozen_string_literal: true | |
source "https://rubygems.org" | |
git_source(:github) {|repo_name| "https://github.com/#{repo_name}" } | |
gem "committee" | |
gem "sinatra" | |
gem "pry" | |
gem "pry-byebug" |
This file contains hidden or 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 file contains hidden or 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
# 2019/02/10現在、Ruby 2.6ではgoogle-protobufが動かない(google-protobufの3.7.0で治る) | |
FROM ruby:2.5.3 | |
RUN gem install grpc grpc-tools |
This file contains hidden or 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
desc 'execute rubocop git diff file only' | |
task diff_rubocop: :environment do | |
system('rubocop -a $( git diff --name-only --diff-filter=AMRC | grep -e ".*\.rb" | paste -s - )') | |
end |
This file contains hidden or 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
def save! | |
post = Post.new(user: user, text: 'text') | |
comment = Comment.new(post: post, text: 'text') | |
exec = IdempotentExecutor.new(user_id: user.id, transaction_type: :post_create, signature: 'abcdefg') | |
exec.idempotent_transaction do | |
Post.transaction do | |
post.save! | |
comment.save! |
This file contains hidden or 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
movl $0, (SP) | |
leaq "".main.func1·f(SB), AX | |
movq AX, 8(SP) | |
pcdata $0, $0 | |
call runtime.newproc(SB) |
This file contains hidden or 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
package main | |
import "fmt" | |
import "time" | |
func main() { | |
go func() { | |
fmt.Println("gopher") | |
}() | |
time.Sleep(time.Second) |
This file contains hidden or 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
tesorflow_host = 'host_address' | |
lib_dir = File.join('/work/proto_ruby') | |
$LOAD_PATH.unshift(lib_dir) unless $LOAD_PATH.include?(lib_dir) | |
Dir.glob('/work/proto_ruby/**/*.rb'){ |path| require_relative(path) unless File.directory? path } | |
require 'chunky_png' | |
float_values = Array.new(28 * 28) | |
img = ChunkyPNG::Image.from_file('/work/image.png') | |
28.times do |i| |