MCPcopy Create free account

hub / github.com/Farama-Foundation/MAgent2 / functions

Functions307 in github.com/Farama-Foundation/MAgent2

Methodadd_reward
src/gridworld/GridWorld.h:284
Methodadd_square
(pos, side, gap)
magent2/environments/gather/gather.py:268
Functionas_bool_c_array
numpy to ctypes array
magent2/c_lib.py:39
Methodaverage_pooling_group
src/gridworld/Map.cc:117
Methodbuild_extensions
(self)
setup.py:39
Methodcalc_event_node
src/gridworld/RewardEngine.cc:216
Methodcalc_index
src/utility/utility.h:46
Methodcalc_reward
src/gridworld/GridWorld.cc:681
Methodcalc_rule
src/gridworld/RewardEngine.cc:373
Functioncheck_model
check whether a model is downloaded
magent2/utility.py:52
Methodclear_area
clear a rectangle
src/gridworld/Map.cc:504
Methodclose
(self)
magent2/environments/magent_env.py:155
Methodcollect_agent_symbol
(node, config)
magent2/gridworld.py:812
Methodcollect_event_node
(node, config)
magent2/gridworld.py:834
Methodcollect_related_symbol
src/gridworld/RewardEngine.cc:71
Methoddraw
(base_x, base_y, data)
magent2/environments/gather/gather.py:307
Functiondraw_line_matrix
(matrix, color, a, b, resolution)
magent2/render.py:69
Functionenv_config_game
src/runtime_api.cc:31
Functionenv_delete_game
src/runtime_api.cc:25
Functionenv_fn
(**kwargs)
magent2/environments/magent_env.py:11
Functionenv_get_info
info getter
src/runtime_api.cc:69
Functionenv_get_reward
src/runtime_api.cc:62
Functionenv_name_format
(str)
docs/scripts/utils.py:31
Functionenv_render_next_file
src/runtime_api.cc:82
Functionenv_set_action
src/runtime_api.cc:50
Functionenv_step
src/runtime_api.cc:56
Methodfill_area
fill a rectangle (x, y) - (x + width, y + height) with specific occupier
src/gridworld/Map.cc:473
Methodform_txt
(index)
magent2/render.py:132
Functiongather_infer_action
src/temp_c_booster.cc:124
Methodgenerate_map
(self)
magent2/environments/adversarial_pursuit/adversarial_pursuit.py:249
Methodgenerate_map
(self)
magent2/environments/tiger_deer/tiger_deer.py:250
Methodgenerate_map
(self)
magent2/environments/battlefield/battlefield.py:228
Methodgenerate_map
(self)
magent2/environments/combined_arms/combined_arms.py:413
Methodgenerate_map
(self)
magent2/environments/battle/battle.py:277
Methodget_action_space
(self, handle)
magent2/environment.py:36
Methodget_align
src/gridworld/Map.cc:408
Methodget_center
src/gridworld/GridWorld.h:293
Methodget_collide
get original occupier in the rectangle who results in a collide with a move intention
src/gridworld/Map.cc:486
Functionget_config
(map_size)
magent2/builtin/config/battle.py:6
Functionget_config
(map_size)
magent2/builtin/config/double_attack.py:8
Functionget_config
(map_size)
magent2/builtin/config/pursuit.py:4
Functionget_config
(map_size)
magent2/builtin/config/forest.py:6
Methodget_feature_size
src/gridworld/GridWorld.cc:926
Methodget_feature_space
(self, handle)
magent2/environment.py:42
Methodget_global_minimap
Compress global map into a minimap of given size. Args: height (int): Height of minimap. width (int): Width of minima
magent2/gridworld.py:695
Methodget_goal
src/gridworld/GridWorld.h:221
Methodget_num
(self, handle)
magent2/environment.py:33
Methodget_observation
(self, handle)
magent2/environment.py:14
Methodget_reward
(self, handle)
magent2/environment.py:29
Methodget_reward
src/gridworld/GridWorld.h:175
Methodget_reward
src/gridworld/GridWorld.h:283
Methodget_view2attack
Get a matrix with the same size of view_range. If element >= 0, then it is an attackable point, and the corresponding action number is
magent2/gridworld.py:671
Methodget_view_space
(self, handle)
magent2/environment.py:39
Functiongridworld_add_reward_rule
src/runtime_api.cc:139
Functiongridworld_clear_dead
run step
src/runtime_api.cc:114
Functiongridworld_define_agent_symbol
reward description
src/runtime_api.cc:127
Functiongridworld_define_event_node
src/runtime_api.cc:133
Functiongridworld_set_goal
src/runtime_api.cc:120
Methodgroup2channel
src/gridworld/GridWorld.cc:915
Methodin_board
* Utility */
src/gridworld/Map.h:81
Methodinit_reward
src/gridworld/GridWorld.h:282
Methodinit_reward_description
src/gridworld/RewardEngine.cc:105
Methodint2pos
src/gridworld/Map.h:94
Methodis_blank_area
check if rectangle (x,y) - (x + width, y + height) is a blank area the rectangle can only contains blank slots and itself
src/gridworld/Map.cc:454
Functionmain
src/gridworld/test.cc:154
Methodmake_channel_trans
private utility
src/gridworld/GridWorld.cc:897
Methodnew_group
Registers a new group of agents into environment. Args: name (str): Name of the group. Returns: handle (ctyp
magent2/gridworld.py:387
Methodobservation_space
(self, agent)
magent2/environments/magent_env.py:101
Methodpos2int
src/gridworld/Map.h:85
Functionraw_env
( map_size=default_map_size, max_cycles=max_cycles_default, minimap_mode=minimap_mode_default,
magent2/environments/adversarial_pursuit/adversarial_pursuit.py:138
Functionraw_env
( map_size=default_map_size, max_cycles=max_cycles_default, minimap_mode=minimap_mode_default,
magent2/environments/tiger_deer/tiger_deer.py:124
Functionraw_env
( map_size=default_map_size, max_cycles=max_cycles_default, minimap_mode=minimap_mode_default,
magent2/environments/battlefield/battlefield.py:159
Functionraw_env
( map_size=default_map_size, max_cycles=max_cycles_default, minimap_mode=minimap_mode_default,
magent2/environments/combined_arms/combined_arms.py:160
Functionraw_env
( map_size=default_map_size, max_cycles=max_cycles_default, minimap_mode=minimap_mode_default,
magent2/environments/battle/battle.py:157
Functionrec_round
round x recursively Parameters ---------- x: float, int, list, list of list, ... variable to round, support many types ndigit
magent2/utility.py:7
Methodrefresh_center
src/gridworld/GridWorld.h:294
Methodrender
(self)
magent2/environment.py:23
Methodrender
Renders a step.
magent2/gridworld.py:735
Methodrender
(self, mode)
magent2/render.py:159
Methodrender
* render */
src/gridworld/GridWorld.cc:939
Methodrender_next_file
(self)
magent2/environment.py:26
Methodreset
(self)
magent2/environment.py:10
Methodreset
Resets the environment to an initial internal state.
magent2/gridworld.py:363
Methodreset
src/gridworld/GridWorld.h:31
Methodreset
src/gridworld/GridWorld.cc:72
Functionrunaway_infer_action
src/temp_c_booster.cc:23
Functionrush_prey_infer_action
src/temp_c_booster.cc:48
Methodset_action
(self, handle, actions)
magent2/environment.py:17
Methodset_action
src/gridworld/GridWorld.h:182
Methodset_center
src/gridworld/GridWorld.h:292
Methodset_channel_id
src/gridworld/Map.h:99
Methodset_goal
src/gridworld/GridWorld.h:225
Methodset_render_dir
Sets the directory to save render file. Args: name (str): Name of render directory.
magent2/gridworld.py:726
Methodstate
Returns an observation of the global environment.
magent2/environments/magent_env.py:220
Methodstep
(self)
magent2/environment.py:20
Methodstep
Runs one timestep of the environment using the agents' actions. Returns: done (bool): Flag indicating whether the game is done or
magent2/gridworld.py:531
Methodstep
(self, all_actions)
magent2/environments/magent_env.py:257
Functiontest_extract_view
src/gridworld/test.cc:64
Functiontest_import_environments
()
tests/test_magent2.py:11
Functiontest_sector_range
src/gridworld/test.cc:14
← previousnext →201–300 of 307, ranked by callers