Getting Started & Examples
First, see Installation to get the holoocean
package and
Ocean
installed.
A minimal HoloOcean usage example is below:
import holoocean
import numpy as np
env = holoocean.make("PierHarbor-Hovering")
# The hovering AUV takes a command for each thruster
command = np.array([10,10,10,10,0,0,0,0])
for _ in range(180):
state = env.step(command)
Notice that:
You pass the name of a scenario into
holoocean.make
See Packages for all of the different worlds and scenarios that are available.
The interface of HoloOcean is designed to be familiar to OpenAI Gym
You can access data from a specific sensor with the state dictionary:
dvl = state["DVLSensor"]
That’s it! HoloOcean is meant to be fairly simple to use.
Check out the different worlds that are available, read the API documentation, or get started on making your own custom scenarios.
Below are some snippets that show how to use different aspects of HoloOcean.
There is also an examples.py in the root of the holoocean repo with more example code.
https://github.com/byu-holoocean/HoloOcean