shutdown_serverservererror

servererror  时间:2021-04-12  阅读:()
Package'gym'October25,2016Version0.
1.
0TitleProvidesAccesstotheOpenAIGymAPIDescriptionOpenAIGymisaopen-sourcePythontoolkitfordevelopingandcomparingreinforcementlearningalgorithms.
ThisisawrapperfortheOpenAIGymAPI,andenablesaccesstoanever-growingvarietyofenvironments.
FormoredetailsonOpenAIGym,pleaseseehere:.
FormoredetailsontheOpenAIGymAPIspecication,pleaseseehere:.
LicenseMIT+leLICENSELazyDatatrueDependsR(>=3.
3.
1)Importshttr,jsonliteURLhttps://github.
com/paulhendricks/gym-RBugReportshttps://github.
com/paulhendricks/gym-R/issuesRoxygenNote5.
0.
1SuggeststestthatNeedsCompilationnoAuthorPaulHendricks[aut,cre]MaintainerPaulHendricksRepositoryCRANDate/Publication2016-10-2500:57:54Rtopicsdocumented:create_GymClient2env_action_space_contains3env_action_space_info3env_action_space_sample4env_close5env_create612create_GymClientenv_list_all6env_monitor_close7env_monitor_start8env_observation_space_info9env_reset9env_step10get_request11gym11parse_server_error_or_raise_for_status12post_request12print.
GymClient13random_discrete_agent14shutdown_server14upload15Index16create_GymClientCreateaGymClientinstance.
DescriptionThisfunctioninstantiatesaGymClientinstancetointegratewithanOpenAIGymserver.
Usagecreate_GymClient(remote_base)Argumentsremote_baseTheURLoftheOpenAIgymserver.
Thisvalueisusually"http://127.
0.
0.
1:5000".
ValueAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)##End(Notrun)env_action_space_contains3env_action_space_containsEvaluatewhetheranactionisamemberofanenvironments'sactionspace.
DescriptionEvaluatewhetheranactionisamemberofanenvironments'sactionspace.
Usageenv_action_space_contains(x,instance_id,action)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
actionAnactiontotakeintheenvironment.
ValueAbooleanatomicvectoroflengthoneindicatingiftheactionisamemberofanenvironments'sactionspace.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)action<-env_action_space_sample(client,instance_id)env_action_space_contains(client,instance_id,action)##End(Notrun)env_action_space_infoGetinformation(nameanddimensions/bounds)oftheenvironments'sactionspace.
DescriptionGetinformation(nameanddimensions/bounds)oftheenvironments'sactionspace.
4env_action_space_sampleUsageenv_action_space_info(x,instance_id)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
ValueAlistcontaining"name"(suchas"Discrete"),andadditionaldimensionalinfo(suchas"n")whichvariesfromspacetospace.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)env_action_space_info(client,instance_id)##End(Notrun)env_action_space_sampleSampleanactionfromtheenvironments'sactionspace.
DescriptionSampleanactionfromtheenvironments'sactionspace.
Usageenv_action_space_sample(x,instance_id)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
ValueAnactionsampledfromaspace(suchas"Discrete"),whichvariesfromspacetospace.
env_close5Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)env_action_space_sample(client,instance_id)##End(Notrun)env_closeFlushallmonitordatatodisk.
DescriptionFlushallmonitordatatodisk.
Usageenv_close(x,instance_id)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
ValueNULL.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)env_close(client,instance_id)##End(Notrun)6env_list_allenv_createCreateaninstanceofthespeciedenvironment.
DescriptionCreateaninstanceofthespeciedenvironment.
Usageenv_create(x,env_id)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
env_idAshortidentier(suchas"3c657dbc")forthecreatedenvironmentinstance.
Theinstance_idisusedinfutureAPIcallstoidentifytheenvironmenttobemanipulated.
ValueAshortidentier(suchas"3c657dbc")forthecreatedenvironmentinstance.
Theinstance_idisusedinfutureAPIcallstoidentifytheenvironmenttobemanipulated.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"env_create(client,env_id)##End(Notrun)env_list_allListallenvironmentsrunningontheserver.
DescriptionListallenvironmentsrunningontheserver.
Usageenv_list_all(x)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
env_monitor_close7ValueAlistmappinginstance_idtoenv_ide.
g.
list("3c657dbc"="CartPole-v0")foreveryenvontheserver.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_list_all(client)##End(Notrun)env_monitor_closeFlushallmonitordatatodisk.
DescriptionFlushallmonitordatatodisk.
Usageenv_monitor_close(x,instance_id)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
ValueNULL.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)env_monitor_close(client,instance_id)##End(Notrun)8env_monitor_startenv_monitor_startStartmonitoring.
DescriptionStartmonitoring.
Usageenv_monitor_start(x,instance_id,directory,force=FALSE,resume=FALSE)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
directoryThedirectorytowritethetrainingdatato.
DefaultstoFALSE.
forceClearoutexistingtrainingdatafromthisdirectory(bydeletingeverylepre-xedwith"openaigym").
DefaultstoNULL.
resumeRetainthetrainingdataalreadyinthisdirectory,whichwillbemergedwithournewdata.
DefaultstoFALSE.
ValueNULL.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)outdir<-"/tmp/random-agent-results"env_monitor_start(client,instance_id,outdir,force=TRUE,resume=FALSE)##End(Notrun)env_observation_space_info9env_observation_space_infoGetinformation(nameanddimensions/bounds)oftheenvironment'sobservationspace.
DescriptionGetinformation(nameanddimensions/bounds)oftheenvironment'sobservationspace.
Usageenv_observation_space_info(x,instance_id)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
ValueAlistcontaining"name"(suchas"Discrete"),andadditionaldimensionalinfo(suchas"n")whichvariesfromspacetospace.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)env_observation_space_info(client,instance_id)##End(Notrun)env_resetResetthestateoftheenvironmentandreturnaninitialobservation.
DescriptionResetthestateoftheenvironmentandreturnaninitialobservation.
Usageenv_reset(x,instance_id)10env_stepArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
ValueTheinitialobservationofthespace.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)env_reset(client,instance_id)##End(Notrun)env_stepStepthoughanenvironmentusinganaction.
DescriptionStepthoughanenvironmentusinganaction.
Usageenv_step(x,instance_id,action,render=FALSE)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
instance_idAshortidentier(suchas"3c657dbc")fortheenvironmentinstance.
actionAnactiontotakeintheenvironment.
renderWhethertorendertheenvironment.
DefaultstoFALSE.
ValueAlistconsistingofthefollowing:action;anactiontotakeintheenvironment,observation;anagent'sobservationofthecurrentenvironment,reward;theamountofrewardreturnedafterpre-viousaction,done;whethertheepisodehasended,andinfo;alistcontainingauxiliarydiagnosticinformation.
get_request11Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)env_id<-"CartPole-v0"instance_id<-env_create(client,env_id)action<-env_action_space_sample(client,instance_id)env_step(client,instance_id,action)##End(Notrun)get_requestSubmitaGETrequesttoanOpenAIGymserver.
DescriptionSubmitaGETrequesttoanOpenAIGymserver.
Usageget_request(x,route,data=NULL)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
routeTheURLpathorendpoint.
dataURLqueryarguments.
DefaultvalueisNULL.
ValueIftheresponsecodeis200or204,aparsedresponse.
Else,aservererrororraisedexception.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)route<-"/v1/envs/"get_request(client,route)##End(Notrun)gymgym:ProvidesAccesstotheOpenAIGymAPIDescriptiongym:ProvidesAccesstotheOpenAIGymAPI12post_requestparse_server_error_or_raise_for_statusParsetheservererrororraiseforstatus.
DescriptionParsetheservererrororraiseforstatus.
Usageparse_server_error_or_raise_for_status(response)ArgumentsresponseAresponseobjectfromhttr::POSTorhttr::GET.
ValueIftheresponsecodeis200or204,aparsedresponse.
Else,aservererrororraisedexception.
Examples##Notrun:b2<-"http://httpbin.
org/post"response<-httr::POST(b2,body="Asimpletextstring")parse_server_error_or_raise_for_status(response)##End(Notrun)post_requestSubmitaPOSTrequesttoanOpenAIGymserver.
DescriptionSubmitaPOSTrequesttoanOpenAIGymserver.
Usagepost_request(x,route,data=NULL)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
routeTheURLpathorendpoint.
dataURLqueryarguments.
DefaultvalueisNULL.
print.
GymClient13ValueIftheresponsecodeis200or204,aparsedresponse.
Else,aservererrororraisedexception.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)route<-"/v1/envs/"env_id<-"CartPole-v0"data<-list(env_id=env_id)post_request(client,route,data)##End(Notrun)print.
GymClientRepresentaGymClientinstanceonthecommandline.
DescriptionRepresentaGymClientinstanceonthecommandline.
Usage##S3methodforclassGymClientprint(x,.
.
.
)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
.
.
.
Furtherargumentspassedtoorfromothermethods.
ValuexAGymClientinstance.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)print(client)##End(Notrun)14shutdown_serverrandom_discrete_agentAsamplerandomdiscreteagent.
DescriptionAsamplerandomdiscreteagent.
Usagerandom_discrete_agent(n)ArgumentsnThenumberofdiscreteactionspacesavailable.
ValueNULL.
Examplesagent<-random_discrete_agent(10)shutdown_serverRequestaservershutdown.
DescriptionRequestaservershutdown.
Usageshutdown_server(x)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
ValueNULLCurrentlyusedbytheintegrationteststorepeatedlycreateanddestroyfreshcopiesoftheserverrunninginaseparatethread.
upload15Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)shutdown_server(client)##End(Notrun)uploadFlushallmonitordatatodisk.
DescriptionFlushallmonitordatatodisk.
Usageupload(x,training_dir,api_key=NULL,algorithm_id=NULL)ArgumentsxAninstanceofclass"GymClient";thisobjecthas"remote_base"asanattribute.
training_dirAdirectorycontainingtheresultsofatrainingrun.
api_keyYourOpenAIAPIkey.
algorithm_idAnarbitrarystringindicatingtheparicularversionofthealgorithm(includingchoicesofparameters)youarerunning.
ValueNULL.
Examples##Notrun:remote_base<-"http://127.
0.
0.
1:5000"client<-create_GymClient(remote_base)outdir<-"/tmp/random-agent-results"upload(client,outdir)##End(Notrun)Indexcreate_GymClient,2env_action_space_contains,3env_action_space_info,3env_action_space_sample,4env_close,5env_create,6env_list_all,6env_monitor_close,7env_monitor_start,8env_observation_space_info,9env_reset,9env_step,10get_request,11gym,11gym-package(gym),11parse_server_error_or_raise_for_status,12post_request,12print.
GymClient,13random_discrete_agent,14shutdown_server,14upload,1516

Fiberia.io:$2.9/月KVM-4GB/50GB/2TB/荷兰机房

Fiberia.io是个新站,跟ViridWeb.com同一家公司的,主要提供基于KVM架构的VPS主机,数据中心在荷兰Dronten。商家的主机价格不算贵,比如4GB内存套餐每月2.9美元起,采用SSD硬盘,1Gbps网络端口,提供IPv4+IPv6,支持PayPal付款,有7天退款承诺,感兴趣的可以试一试,年付有优惠但建议月付为宜。下面列出几款主机配置信息。CPU:1core内存:4GB硬盘:...

10GBIZ(月$2.36 ), 香港和洛杉矶CN2 GIA

10GBIZ服务商经常有看到隔壁的一些博客分享内容,我翻看网站看之前有记录过一篇,只不过由于服务商是2020年新成立的所以分享内容比较谨慎。这不至今已经有将近两年的服务商而且云服务产品也比较丰富,目前有看到10GBIZ服务商有提供香港、美国洛杉矶等多机房的云服务器、独立服务器和站群服务器。其中比较吸引到我们用户的是亚洲节点的包括香港、日本等七星级网络服务。具体我们看看相关的配置和线路产品。第一、香...

阿里云香港 16核32G 20M 999元/月

阿里云香港配置图提速啦是成立于2012年的十分老牌的一个商家这次给大家评测的是 阿里云香港 16核32G 20M 这款产品,单单说价格上就是十分的离谱原价8631元/月的现价只要 999元 而且还有个8折循环优惠。废话不多说直接进入正题。优惠时间 2021年8月20日-2021年9月20日 优惠码 wn789 8折优惠阿里云香港BGP专线 16核32G 10M带宽 优惠购买 399元购买链接阿里云...

servererror为你推荐
孩子ipadphpweb破解wifi破解黑科技linux防火墙设置在linux iptables怎么开启支付宝蜻蜓发布怎么取得支付宝蜻蜓二代的代理?新iphone也将禁售现在2017年iPhone6s还有多久会被淘汰csamy滴滴估值500亿滴滴流水每天280元一个月下来能赚 多少抢米网抢小米手机需要下什么软件 速求网络u盘你们谁知道网络硬盘怎么用网站后台密码破解网站后台管理密码忘记了怎么破解啊高手进来.
二级域名查询 国际域名抢注 韩国vps 汉邦高科域名申请 免费申请域名 132邮箱 轻博客 云图标 圣诞促销 ntfs格式分区 100m独享 服务器托管什么意思 卡巴斯基免费试用版 根服务器 域名dns 重庆电信服务器托管 vul php服务器 免费网络 数据湾 更多