了解grid2op仿真环境(一)

00_Introduction

substation:变电站

powerline:电线

load:?

busbar:汇流排

A “bus” is a fancy word from the power system community meaning that: if two objects are on the same bus, then there exist a direct electrical path in the substation connecting them.

在这里插入图片描述

  1. learn to control the switches
  2. for each object, decide on which busbar (a or b) it should be connected

substations:

powerlines:

connection or disconnection, that is a question.

constraint: Parameters class

  • NB_TIMESTAMP_COOLDOWN_LINE: how many timestamps you have to wait before redoing an action.
  • NB_TIMESTAMP_COOLDOWN_SUB: how many timestamps you have to wait before making an action on the same substation again.

01_The most basic use of Grid2Op

creating an environment

To define/create it, we can call:

env = grid2op.make("rte_case14_redisp", test=True)

ln this example we will use the rte case14 redisp environment, in test mode.

The make function is highly customizable.

grid2op.runner API

与从头构建en环境(见上一节)相反,这需要更少的工作:我们不需要初始化实例化)任何东西。所有的事情都在runner内部进行,由main函数调用。

from grid2op.Runner import Runner

runner = Runner(**env.get_params_for_runner(), agentClass=DoNothingAgent)

res = runner.run(nb_episode=1, max_iter=max_iter)

A call of the single 2 lines above will:

  • Create a valid environment.
  • Create a valid agent.
  • Assess how well an agent performs on one episode.

02_How to build an Agent and assess its performance

expert agents that take actions based on fixed rules

the observation class
  1. obtaining an observation

    env = grid2op.make(test=True)
    obs = env.reset() 
    
  2. information contained

    • calendar data:year/month/day/hour_of_day/day_of_week
    • powergrid generic information: static in the same environment
    • about the generators
    • about the loads
    • about the powerlines
    • connectivity matrix
    • etc…
taking actions based on the observation

在这里插入图片描述

03_Action class

2 concepts that will affect the objects differently:

  • change:
    • powerline: connected<->disconnected
    • object: connected to bus 1<->bus 2
  • set: (regardless of its previous status)
    • connect/disconnect a powerline
    • assign the object to a specific bus

ambiguous action: 看起来不合理的动作。

curtailment: limiting the production of renewable generator

storage units: 正数吸收,负数释放。

Actions can be combined.

input:

action_space.get_obj_connect_to(substation_id=1)

output:

{'loads_id': array([0], dtype=int64),
 'generators_id': array([0], dtype=int64),
 'lines_or_id': array([2, 3, 4], dtype=int64),
 'lines_ex_id': array([0], dtype=int64),
 'storages_id': array([], dtype=int64),
 'nb_elements': 6}
  • 3
    点赞
  • 2
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值