2017-09-06 安兴乐-siler
什么是强化学习 简单通俗来讲就是Agent在Environment中探索找到最优策略Policy,使得Reward最多的学习策略(游戏)。它是一个MDP(Markov Decision Process)马尔可夫决策过程:一个状态$S_{t}$是MarKov当且仅当 $P(S_{t+1}|S_{t})=P(S_{t+1}|S_{t},S_{t-1},...,S_{0})$。再通俗点讲就是未来只取决于现在。 继续阅读 »
2014-12-09 Mithrilwoodrat
这几个实验都是上课时候一两小时实现的,因为老师给出的参考代码有些惨不忍睹(虽然我写的也没好到哪去).因为时间有限,就没用C++. 同样是因为时间有限,仅供参考,有bug概不负责. 代码如下 # -- coding: utf-8 -- class Bank(object): def init(self): self.totalpro = 0 self.process = [] self.res_num = 4 self.res_type = ['A', 'B', 'C', 'D'] self.Resources = {'A':10, 继续阅读 »
2016-08-29 ruki
New features Add wait multi-processes interface Add uuid generator Add hash library module Add __tb_deprecated__ keyword and option Changes Move some utils interfaces to the hash module Rewrite random generator Bugs fixed Fix stdout compatibility issue for vs2015 Fix process arguments length limit 继续阅读 »
2014-09-22 Kun Ren
Twelve days after the initial commit, pipeR tutorial is released! If you want to write R code fluently and process data elegantly, I strongly recommend that you read this tutorial which is designed to serve as a complete guide to pipeR package, including how it works with dplyr, rlist, and rvest with vivid examples. 继续阅读 »
2016-11-25 Lim Geng
前言 每次写文章都想在前面提提~~事实~~时事,今天想说的是:*******,如果你看到的是星号,那很抱歉,“福利”被和谐了,你可以更换浏览器试试。本文对setTimeout、setImmediate、process.nextTick的区别做了简单阐述,如有疑问,请留言。 api介绍 setTimeout(callback, delay):经过delay时间后只执行一次callback,但是并不能保证时间点的精确性。delay的意思是,告诉callback可以被执行了,如果callback所在队列前面还有任务没执行,那它也得稍等等。 **setImmediate(callback)**:执行callback的时机是在IO 继续阅读 »
2015-10-08 Eric Wang
开发环境:Python 3.4.3 (v3.4.3:9b73f1c3e601, Feb 24 2015, 22:44:40) [MSC v.1600 64 bit (AMD64)] on win32 自序 也许你会说,我为什么要学习使用CSV模块呢?没有CSV模块我一样可以解析操作CSV文件,比如下面这种代码: python with open('stocks.csv') as f: for line in f: row = line.split(',') # process row ... 使用这种方式的一个缺点就是你仍然需要去处理一些棘手的细节问题。比如,如果某些字段值被引号包围,你不得不去除这些引 继续阅读 »
2016-07-18 ruki
最近在xmake中,用lua的协程实现了多任务编译,效果还是不错的,不过后来发现一个问题: 如果所有编译进程都在处理编译,没有退出的时候,xmake的lua主进程会不断地在这些任务间,不停的切换轮询进程的状态,但是有没有机会执行其他任务,导致cpu过高,抢占了编译进程的cpu时间。。 那如果在等不到完成的进程时候,加入sleep等待呢,又会导致编译速度变慢,没法合理利用cpu。。 因此,为了解决这个问题,我打算扩展下lua的接口,实现了一个跨平台的多进程等待接口: process.waitlist 实现多个未完成进程的同时等待,让出xmake主进程的cpu时间,给其他编译进程充分利用 xmake中的lua代码如下: ``` 继续阅读 »
2016-01-07 Klaus Ma
Introduction The purpose of this document is to give an introduction and overall description of the contribution process for contributors new to Mesos. This document is intended to extend the existing documentation with a focus on on-boarding contributors to the community as quickly as possible. 继续阅读 »