Skip to content

Commit

Permalink
adjusted readme example to new top lvl api
Browse files Browse the repository at this point in the history
  • Loading branch information
marvin-steinke committed May 23, 2024
1 parent 6ae1a23 commit cc4e822
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,23 +23,18 @@ Vessim can simulate large numbers of microgrids in parallel, comes with ready-to
The scenario below simulates a microgrid consisting of a simulated computing system (which consistently draws 400W), a single producer (a solar power plant who's production is modelled based on a dataset provided by [Solcast](https://solcast.com/)), and a battery. The *Monitor* periodically stores the energy system state.

```python
from vessim.actor import ComputingSystem, Generator
from vessim.controller import Monitor
from vessim.cosim import Environment
from vessim.power_meter import MockPowerMeter
from vessim.signal import HistoricalSignal
from vessim.storage import SimpleBattery
import vessim as vs

environment = Environment(sim_start="15-06-2022")
environment = vs.Environment(sim_start="15-06-2022")

monitor = Monitor()
monitor = vs.Monitor()
environment.add_microgrid(
actors=[
ComputingSystem(power_meters=[MockPowerMeter(p=400)]),
Generator(signal=HistoricalSignal.from_dataset("solcast2022_global"), column="Berlin"),
vs.ComputingSystem(power_meters=[vs.MockPowerMeter(p=400)]),
vs.Generator(signal=vs.HistoricalSignal.from_dataset("solcast2022_global"), column="Berlin"),
],
controllers=[monitor],
storage=SimpleBattery(capacity=100),
storage=vs.SimpleBattery(capacity=100),
step_size=60,
)

Expand Down

0 comments on commit cc4e822

Please sign in to comment.