Planning and Learning with Tabular MethodsDongmin Lee
Hello~!
This material is reviewed by Dong-Min Lee.
(http://www.facebook.com/dongminleeai)
A reviewed material is Chapter 8. Planning and Learning with Tabular Methods in Reinforcement Learning: An Introduction written by Richard S. Sutton and Andrew G. Barto.
Outline is
1) Introduction
2) Models and Planning
3) Dyna: Integrating Planning, Acting, and Learning
4) When the Model Is Wrong
5) Prioritized Sweeping
6) Expected vs. Sample Updates
7) Trajectory Sampling
8) Planning at Decision Time
9) Heuristic Search
10) Rollout Algorithms
11) Monte Carlo Tree Search
12) Summary
I'm happy to be reviewed Sutton book~!!!
I hope everyone who studies Reinforcement Learning sees this material and help! :)
Thank you!
SLiPP 19차 스터디 웨비나 발표자료 - https://www.slipp.net/wiki/pages/viewpage.action?pageId=52527888
2018년 봄, 유리멘탈 개복치 개발자 이야기를 SLiPP 세미나에서 했습니다. 그 이후 커뮤니티의 도움을 정말 많이 받으면서 재밌는 경험을 해왔습니다. 저처럼 막막한(했던) 사람들을 위해 경험을 나누고 싶어요! 회사 밖에서 경험들- 커뮤니티, Civic hacking, 프로그래밍 교육 실험, 개발행사 운영경험 을 공유해보려고 해요.
#회사_밖_경험 #개복치_개발자 #개복치는_성장하면_천적이_없대요 #근데언제성장하죠 #야너두
An Introduction to Makefile.
about 23 slides to present you a quick start to the make utility, its usage and working principles. Some tips/examples in order to understand and write your own
Makefiles.
In this presentation you will learn why this utility continues to hold its top position in project build software, despite many younger competitors.
Visit Do you know Magazine : https://www.facebook.com/douknowmagazine
If you can write some code patch, it will be one of great ways for contributing open-sources. but, there is no way to contribute open-sources without writing code? I'd like to encourage doing translation, filing a bug and so on. This is a case study for that. Don't need anything else! Please join us and enjoy! :)
Planning and Learning with Tabular MethodsDongmin Lee
Hello~!
This material is reviewed by Dong-Min Lee.
(http://www.facebook.com/dongminleeai)
A reviewed material is Chapter 8. Planning and Learning with Tabular Methods in Reinforcement Learning: An Introduction written by Richard S. Sutton and Andrew G. Barto.
Outline is
1) Introduction
2) Models and Planning
3) Dyna: Integrating Planning, Acting, and Learning
4) When the Model Is Wrong
5) Prioritized Sweeping
6) Expected vs. Sample Updates
7) Trajectory Sampling
8) Planning at Decision Time
9) Heuristic Search
10) Rollout Algorithms
11) Monte Carlo Tree Search
12) Summary
I'm happy to be reviewed Sutton book~!!!
I hope everyone who studies Reinforcement Learning sees this material and help! :)
Thank you!
SLiPP 19차 스터디 웨비나 발표자료 - https://www.slipp.net/wiki/pages/viewpage.action?pageId=52527888
2018년 봄, 유리멘탈 개복치 개발자 이야기를 SLiPP 세미나에서 했습니다. 그 이후 커뮤니티의 도움을 정말 많이 받으면서 재밌는 경험을 해왔습니다. 저처럼 막막한(했던) 사람들을 위해 경험을 나누고 싶어요! 회사 밖에서 경험들- 커뮤니티, Civic hacking, 프로그래밍 교육 실험, 개발행사 운영경험 을 공유해보려고 해요.
#회사_밖_경험 #개복치_개발자 #개복치는_성장하면_천적이_없대요 #근데언제성장하죠 #야너두
An Introduction to Makefile.
about 23 slides to present you a quick start to the make utility, its usage and working principles. Some tips/examples in order to understand and write your own
Makefiles.
In this presentation you will learn why this utility continues to hold its top position in project build software, despite many younger competitors.
Visit Do you know Magazine : https://www.facebook.com/douknowmagazine
If you can write some code patch, it will be one of great ways for contributing open-sources. but, there is no way to contribute open-sources without writing code? I'd like to encourage doing translation, filing a bug and so on. This is a case study for that. Don't need anything else! Please join us and enjoy! :)
Wrapped in a single session, you'll find the concepts and techniques that convert the average Git practitioner into a master of the craft. We'll go from technical topics like "efficient conflict resolution" and "effective code cleanup," to the often-asked "how to handle project dependencies with Git" and "how to manage massive repositories." And much more.
Take care of hundred containers and not go crazyHonza Horák
Imagine you have four different databases, five popular languages, and six other interesting technologies, that you want to put into container image, make them nicely run in OpenShift, and support for few years. However, you soon realize that you want to support not only one version of the particular technology, and the images are not based on one distribution only. Then you easily find yourself developing and maintaining hundred of container images or more.
Something similar happened to us and I admit we did not know all the tricks from the first minute. Come and hear what issues we met during the way, so you do not repeat them as well. We will cover upstream/downstream design, de-duplication of the sources from more perspectives, automation based on Jenkins, and of course testing.
Ruby is just over 20 years old. It's no longer young or hip, and that’s a good thing! In the last decade, Ruby has matured as a web technology. It's being used in many successful companies out there such as Hulu, GitHub, and Bloomberg. The ecosystem is comprised of many stable libraries and tools to handle most common web tasks, allowing you to focus on adding features to improve your product and better serve your customers. We'll talk about how you can build scalable and reliable software, but still maintain fast development turnaround by leveraging the maturity and creativity of the Ruby community.
2. Who am I?
Hi! My name is Raül Pérez
● Lead Software Engineer at Carrenza Ltd. http://www.carrenza.com
● Living between Barcelona & London.
● Working on devops stuff, but I’m still more a Dev than an Op.
● Proud to be a Gopher, but I’m not a fanboy. I write code on multiple
languages.
Twitter: https://twitter.com/repejota
Github: https://github.com/repejota
LinkedIn: https://linkedin.com/in/repejota
Raül Pérez - @repejota GolangBCN - 25/11/2015
4. Why using Makefiles?
● Build != Compile
○ Building a project means more than just compile your code.
○ Static analysis, Linters, Installation, configuration, packaging, etc ...
● Same tool on each phase of the project.
○ Makefiles act as the glue to go tools (build, install, clean)
○ But can use also third party tools ( go lint, go vet, gb, etc ... )
● Language agnostic.
○ Probably your project does not rely on just one language.
○ Generate configuration files, man pages, fixture data, etc ...
● Available on multiple platforms.
○ Because users use whatever they want.
○ Cross compilation.
Raül Pérez - @repejota GolangBCN - 25/11/2015
5. Why using Makefiles? (II)
Three goals are necessary to accomplish when you properly want to build your
project:
1. Easy & portable compilation, installation and cleanup.
2. Make trivial to use compile time variables.
3. Reproducible builds.
Raül Pérez - @repejota GolangBCN - 25/11/2015
6. Example code to build.
package main
import “fmt”
func main() {
// Probably the most awesome piece of code you’ve ever seen.
fmt.Println(“foo bar”)
}
Raül Pérez - @repejota GolangBCN - 25/11/2015
10. Easy compilation, installation and cleanup (I).
Compilation: Just type “make”
○ Laziness! Less keystrokes than “go build <package>”
○ You can also build multiple projects with a single Makefile.
■ A Makefile could call to another Makefile.
○ Want to use more sophisticated build tool with your code?
■ All scripts and data to build a project belongs to the project itself.
■ Just change the Makefile not your continuous integration process.
Raül Pérez - @repejota GolangBCN - 25/11/2015
11. Easy compilation, installation and cleanup (II).
Installation: Just type “make install”
○ Most of the times “go install <package>” is not enough, there is probably extra steps to do
after creating the binary.
○ Generate configuration files, man pages, fixture data, etc ...
○ Just change the Makefile not your deployment process.
Raül Pérez - @repejota GolangBCN - 25/11/2015
12. Easy compilation, installation and cleanup (III).
Cleanup: Just type “make clean”
○ Cleaning your project means more than just deleting your old binary.
Raül Pérez - @repejota GolangBCN - 25/11/2015
13. Improved Makefile
# Default target: builds the project
build:
go build
# Installs our project: copies binaries
install:
go install
# Cleans our project: deletes binaries
clean:
go clean
Raül Pérez - @repejota GolangBCN - 25/11/2015
14. Demo
$ ls -al
total 16
drwxr-xr-x 4 raul staff 136 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ make
go build
$ ls -al
total 4560
drwxr-xr-x 5 raul staff 170 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rwxr-xr-x 1 raul staff 2324096 25 Nov 05:08 gomake
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ ./gomake
foo bar
$ make clean
go clean
$
Raül Pérez - @repejota GolangBCN - 25/11/2015
16. Make trivial to use compile time variables
● Adding a VERSION number.
● Adding the Build Time.
Raül Pérez - @repejota GolangBCN - 25/11/2015
17. Improved source code.
package main
import (
“fmt”
)
// Variables to identify the build
var (
Version = “1.0.0”
Build = “2015-11-25T00:23:32+0100”
)
func main() {
fmt.Println(“Version: “, Version)
fmt.Println(“Build Time: “, Build)
}
Raül Pérez - @repejota GolangBCN - 25/11/2015
18. Improved Makefile
# This how we want to name the binary output
BINARY=gomake
# Builds the project
build:
go build -o ${BINARY}
# Installs our project: copies binaries
install:
go install
# Cleans our project: deletes binaries
clean:
if [ -f ${BINARY} ] ; then rm ${BINARY} ; fi
.PHONY: clean install
Raül Pérez - @repejota GolangBCN - 25/11/2015
19. Demo
$ ls -al
total 16
drwxr-xr-x 4 raul staff 136 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ make
go build
$ ls -al
total 4560
drwxr-xr-x 5 raul staff 170 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rwxr-xr-x 1 raul staff 2324096 25 Nov 05:08 gomake
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ ./gomake
Version: 1.0.0
Build Time: 2015-11-25T00:23:32+0100
$ make clean
if [ -f gomake ] ; then rm gomake ; fi
$
Raül Pérez - @repejota GolangBCN - 25/11/2015
20. Make trivial to use compile time variables (II)
● Adding a VERSION number.
○ Editing the code to bump the version is painful.
○ Your are going to forget it, commit, and your git history is going to be broken.
● Adding a Build Time.
○ It happens the same than with the VERSION.
○ Which format of timestamp to use? It is a weird string!
○ And obviously you need a clock to check the exact time before! :P
Raül Pérez - @repejota GolangBCN - 25/11/2015
21. Improved source code.
package main
import (
“fmt”
)
// Variables to identify the build
var (
Version string
Build string
)
func main() {
fmt.Println(“Version: “, Version)
fmt.Println(“Build Time: “, Build)
}
Raül Pérez - @repejota GolangBCN - 25/11/2015
22. Improved Makefile
# This how we want to name the binary output
BINARY=gomake
# These are the values we want to pass for VERSION and BUILD
VERSION=1.0.0
BUILD=`date +%FT%T%z`
# Setup the -ldflags option for go build here, interpolate the variable values
LDFLAGS=-ldflags "-X main.Version=${VERSION} -X main.Build=${BUILD}"
# Builds the project
build:
go build ${LDFLAGS} -o ${BINARY}
# Installs our project: copies binaries
install:
go install ${LDFLAGS}
# Cleans our project: deletes binaries
clean:
if [ -f ${BINARY} ] ; then rm ${BINARY} ; fi
.PHONY: clean install
Raül Pérez - @repejota GolangBCN - 25/11/2015
23. Demo
$ ls -al
total 16
drwxr-xr-x 4 raul staff 136 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ make
go build
$ ls -al
total 4560
drwxr-xr-x 5 raul staff 170 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rwxr-xr-x 1 raul staff 2324096 25 Nov 05:08 gomake
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ ./gomake
Version: 1.0.0
Build Time: 2015-11-25T05:23:32+0100
$ make clean
if [ -f gomake ] ; then rm gomake ; fi
$
Raül Pérez - @repejota GolangBCN - 25/11/2015
24. Make trivial to use compile time variables (III)
● Using LDFLAGS
○ The go link command allows you to set string variables at compile time with the -X option.
○ Use the format: importpath.name=value
○ http://golang.org/cmd/link/
● Differences between Golang 1.5+ and previous version.
○ Golang 1.5+ -X option takes one argument split on the first = sign.
○ Example:
■ go build -ldflags “-X main.Version=1.0.0 -X main.Build=2015-11-25T00:23:32+0100”
○ Golang < 1.5 -X options takes two separate arguments.
○ Example:
■ go build -ldflags “-X main.Version 1.0.0 -X main.Build 2015-11-25T00:23:32+0100”
Raül Pérez - @repejota GolangBCN - 25/11/2015
26. Reproducible builds.
● Delivering binaries is hard.
○ You just can’t serve the binary over Internet.
○ Packages, installators there is plenty of tools to help you.
● You must be sure your binary is not modified or compromised.
○ Once the binary leaves your server you are not controlling it.
○ Also, a security attack can replace your binary on your server for a malicious one.
● shasum all your binaries!
○ Checking the finger-print of your binary allows you to ensure the binary has not been modified
without permission.
Raül Pérez - @repejota GolangBCN - 25/11/2015
27. Reproducible builds (II).
● Our previous example introduces a new problem.
○ Using a timestamp variable changes the shashum of your file!
○ Just avoiding the build time fixes the problem.
○ But then, you’re forced to bump the version on each build.
● Why not use the Git commit hash instead of the timestamp?
○ Can work together with the VERSION.
○ You are not anymore forced to bump a version on each build. Nightly builds!!
○ It doesn’t change if the source code is not modified.
○ Identifies your binary, so you can know its “origin”.
Raül Pérez - @repejota GolangBCN - 25/11/2015
28. Demo
$ ls -al
total 16
drwxr-xr-x 4 raul staff 136 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ make
go build
$ shasum gomake
c6dd654ffe6f0e5af518d281da702187cc577cd4 gomake
$ make
go build
$ shasum gomake
dbf0cbe34067c42ecf6d221fcd789073370fa297 gomake
$
Raül Pérez - @repejota GolangBCN - 25/11/2015
29. Demo
$ ls -al
total 16
drwxr-xr-x 4 raul staff 136 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ make
go build
$ shasum gomake
c6dd654ffe6f0e5af518d281da702187cc577cd4 gomake
$ make
go build
$ shasum gomake
dbf0cbe34067c42ecf6d221fcd789073370fa297 gomake
$
Different shasum values!
Raül Pérez - @repejota GolangBCN - 25/11/2015
30. Final source code.
package main
import (
“fmt”
)
// Variables to identify the build
var (
Version string
Build string
)
func main() {
fmt.Println(“Version: “, Version)
fmt.Println(“Git commit hash: “, Build)
}
Raül Pérez - @repejota GolangBCN - 25/11/2015
31. Final Makefile
# This how we want to name the binary output
BINARY=gomake
# These are the values we want to pass for VERSION and BUILD
VERSION=1.0.0
BUILD=`git rev-parse HEAD`
# Setup the -ldflags option for go build here, interpolate the variable values
LDFLAGS=-ldflags "-X main.Version=${VERSION} -X main.Build=${BUILD}"
# Default target
.DEFAULT_GOAL: $(BINARY)
# Builds the project
$(BINARY):
go build ${LDFLAGS} -o {$BINARY} ./..
# Installs our project: copies binaries
install:
go install ${LDFLAGS} -o {$BINARY} ./..
# Cleans our project: deletes binaries
clean:
if [ -f ${BINARY} ] ; then rm ${BINARY} ; fi
.PHONY: clean install
Raül Pérez - @repejota GolangBCN - 25/11/2015
32. Demo
$ ls -al
total 16
drwxr-xr-x 4 raul staff 136 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ make
go build
$ shasum gomake
b2c879490419f5a6473fa9d290f49a7e6a5b3353 gomake
$ make
go build
$ shasum gomake
b2c879490419f5a6473fa9d290f49a7e6a5b3353 gomake
$
Raül Pérez - @repejota GolangBCN - 25/11/2015
33. Demo
$ ls -al
total 16
drwxr-xr-x 4 raul staff 136 25 Nov 05:08 .
drwxr-xr-x 9 raul staff 306 25 Nov 03:36 ..
-rw-r--r-- 1 raul staff 19 25 Nov 03:11 Makefile
-rw-r--r-- 1 raul staff 132 25 Nov 05:07 main.go
$ make
go build
$ shasum gomake
b2c879490419f5a6473fa9d290f49a7e6a5b3353 gomake
$ make
go build
$ shasum gomake
b2c879490419f5a6473fa9d290f49a7e6a5b3353 gomake
$
Same shasum values!
Reproducible builds!!
Raül Pérez - @repejota GolangBCN - 25/11/2015