Revolve2: Computational Intelligence Group experimentation tools and standards.
Project description
Revolve2
Revolve2 is a collection of Python packages used for researching evolutionary algorithms and modular robotics. Its primary features are a modular robot framework, an abstraction layer around physics simulators, and evolutionary algorithms.
Documentation: ci-group.github.io/revolve2
Installation: ci-group.github.io/revolve2/installation
Get help: github.com/ci-group/revolve2/discussions/categories/ask-for-help
Sample
Here we create and simulate a modular robot, and then calculate how far it moved over the xy plane. This is a shortened version of examples/evaluate_single_robot
.
# (...) Omitted preamble
# Create a modular robot.
body = modular_robots_v1.gecko_v1()
brain = BrainCpgNetworkNeighborRandom(body=body, rng=rng)
robot = ModularRobot(body, brain)
# Create a scene.
scene = ModularRobotScene(terrain=terrains.flat())
scene.add_robot(robot)
# Create a simulator.
simulator = LocalSimulator(headless=False)
# Simulate the scene and obtain states sampled during the simulation.
scene_states = simulate_scenes(
simulator=simulator,
batch_parameters=make_standard_batch_parameters(),
scenes=scene,
)
# Get the state at the beginning and end of the simulation.
scene_state_begin = scene_states[0]
scene_state_end = scene_states[-1]
# Retrieve the states of the modular robot.
robot_state_begin = scene_state_begin.get_modular_robot_simulation_state(robot)
robot_state_end = scene_state_end.get_modular_robot_simulation_state(robot)
# Calculate the xy displacement of the robot.
xy_displacement = fitness_functions.xy_displacement(
robot_state_begin, robot_state_end
)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Hashes for revolve2_ci_group-1.0.0rc1-cp311-cp311-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | d433d834b4132fe64e64586b4bf704c90bd5b77ec973aca3f4fb7bcae7fba326 |
|
MD5 | 97811e674f7a16c61fdd4f1067576a62 |
|
BLAKE2b-256 | c4f1ed29c95def2954e1e671ed0abd630e57c5dd81837375eae9a992066fed48 |
Hashes for revolve2_ci_group-1.0.0rc1-cp311-cp311-musllinux_1_1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | ea60ee3ac1443e00ceddad1d336ef1ee3b5873d8f8cdaa7cff873dc68809c9d2 |
|
MD5 | 7671960bcbdbac8702424307908a2cce |
|
BLAKE2b-256 | 1ac892d6281b6d22f795c4c5110c78f0f08fbf40344206499c96365125301872 |
Hashes for revolve2_ci_group-1.0.0rc1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 3fd808dac4244badb96090a24674ac864d04cfc37f672082dca71417b4263bd8 |
|
MD5 | 494a636d7b03a2c50cbf2ab7890d3ea7 |
|
BLAKE2b-256 | df52882e30d8731fe066c379236013be02d194090c3fb154bbcdb9c6462e0719 |
Hashes for revolve2_ci_group-1.0.0rc1-cp310-cp310-win_amd64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | dfd9c4d16b05e4e976e176cdba56b81293d0bf705c6d367d2366bfbcf35df68f |
|
MD5 | c2b984872a4dbad4dc886d38bb375768 |
|
BLAKE2b-256 | e64eeb53b9804e1ec3fd4e14eae4087b7f1aea6412b5ec93d56bb632ac898821 |
Hashes for revolve2_ci_group-1.0.0rc1-cp310-cp310-musllinux_1_1_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 0fcb34cdd3603e7dd5baa7a2b3487828474a41ddafa93d8ed0e4e35ed54cfe91 |
|
MD5 | f150f9d49f66b44c61e9ad6b9c342573 |
|
BLAKE2b-256 | b8e8a792b6cb0fa8080fdd59dadb5d316bd297e7615fd5a9b4d3955edeca031a |
Hashes for revolve2_ci_group-1.0.0rc1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 03c96752f9fa941f7c79ce3bc3e4bdcb54d841e2db52df14572efc49f18fb165 |
|
MD5 | 473040c71fa6cab62797bc41d5fedd16 |
|
BLAKE2b-256 | a0ae0a443f33e51da396c15753f9b6f644313a0736301b34b34873a9b28ade39 |