AI Glossary / Reinforcement learning and robotics / Intermediate

Global costmap

Definition

A global costmap is a spatial cost representation used to support planning a route across an operating area. In mobile robotics, it typically covers a broader region than the nearby map used for immediate control. It combines information about traversable space, obstacles and navigation costs so a planner can evaluate paths towards a goal.

What it means

Global refers to the planning role and spatial scope, not a promise to represent the whole world. A global costmap might cover one building, a warehouse or a selected planning window. It also does not mean that the information is perfectly current or that the resulting path is globally optimal under every constraint.

The costmap supplies environmental information. The global planner uses that information to compute a route, while a controller handles execution using its own inputs and constraints. These components perform different jobs.

How it works

A navigation system constructs a grid or other cost representation in a configured coordinate frame. In a common layered arrangement, a stored map contributes persistent geometry, sensor layers add observations, and inflation raises costs around obstacles. Restrictions or preferences can contribute further information.

The global planner searches this representation for a suitable path. Updates or changed goals can trigger replanning according to system configuration. A global costmap can include live information; it is not inherently static. Extent, resolution, unknown-space policy and robot footprint must fit the application. Local control still needs to handle conditions that the global representation misses or has not yet incorporated.

Three practical examples

1. A warehouse robot plans from a loading area to a storage aisle using a building-scale costmap that represents walls and restricted zones.

2. A simulated service robot compares two corridors around a central obstacle. The global representation helps identify a route before nearby control follows it.

3. A facility closes a passage for maintenance. Updating the relevant global layer allows later route planning to account for the closure, provided the information reaches the planner and replanning occurs.

Think of it this way

Think of a route-planning floor plan that carries travel annotations. It helps choose which corridors to use across the building. A person walking the route still watches the immediate surroundings. Likewise, a global costmap supports the broader route decision, while nearby sensing and control handle the unfolding journey. Neither view is a substitute for the other.

Worked example

Suppose a rectangular operating area measures 20 meters by 10 meters. With square cells 0.1 meter wide, a global grid needs 20/0.1 = 200 columns and 10/0.1 = 100 rows, giving 20,000 cells.

Halving cell width to 0.05 meter produces 400 columns and 200 rows, or 80,000 cells. Doubling linear resolution therefore quadruples the number of cells for the same area. If one raw cost layer stores one byte per cell, those arrays require 20,000 and 80,000 bytes respectively, excluding metadata, other layers and runtime overhead.

Now suppose the goal lies 15 meters from the start, beyond a separate local window extending only 3 meters around the robot. The larger global representation can contain both locations and the connecting corridors; the local window cannot show the complete route at once.

These dimensions are invented. They demonstrate coverage and storage scaling, not recommended settings or a prediction of total planner runtime.

Illustrative case study

Fictional case: Elm Navigation tests a robot in a simulated distribution center. The global costmap contains the building layout, but a recently blocked corridor has only been marked in a nearby sensor layer. The planner keeps proposing the old route, and the local controller repeatedly stops.

The team checks which observations update each map, how long they persist and when replanning is requested. It then tests the closure and reopening of the corridor while inspecting the two representations separately. This invented case illustrates coordination between mapping, planning and control; it reports no actual deployment or measured improvement.

Common misconceptions and mistakes

A global costmap is not the path itself. The planner computes a path from costs and other assumptions. It is also not necessarily a read-only map loaded once at startup; sensor and rule layers can change it.

Global and local do not automatically imply fixed resolutions or update rates. These are configuration choices. A finer grid can increase computation without fixing stale observations or localization errors. Finally, a path that appears clear on a global map may still be unsuitable for the robot's shape, turning constraints or current surroundings unless the complete navigation stack accounts for them.

Business use

Global costmaps help express the operating area's persistent structure and navigation rules. Teams should establish how layout changes, temporary closures and restricted regions enter the representation, and who checks that updates take effect.

Evaluate route completion, replanning behavior, resource use and consistency with local control. Test goals near map boundaries and situations involving unknown space. When a route fails, distinguish missing map coverage, incorrect costs, planner limitations and execution problems. This separation helps diagnose the issue without assuming every navigation failure requires a different planning algorithm.

People also ask

Does global mean the map is geographically worldwide?

No. It refers to the scope of route planning within the configured operating area.

Can a global costmap use live sensor data?

Yes, depending on its layers and configuration. Global does not mean permanently static.

Must it have a coarser resolution than the local costmap?

No. That may be a design choice, but the roles do not impose one universal resolution relationship.

Check your understanding

Why does changing cell width from 0.1 meter to 0.05 meter quadruple the cell count in the worked example?

Answer: Both the number of columns and the number of rows double. Multiplying the two dimensions gives four times as many cells for the same two-dimensional area.

Related terms

  • Costmap
  • Local costmap
  • Path planning
  • Localization
  • global planner
  • map frame
  • obstacle layer
  • inflation layer
  • replanning

Learn next

Understand a general costmap before configuring a global one. Choose coverage and resolution based on the operating area, then inspect how each layer contributes costs. Test map updates and replanning alongside local control, including closures, unknown areas and goals near boundaries.

  • Costmap

More in Reinforcement learning and robotics

  • Exploring starts - Exploring starts is an assumption or sampling arrangement in episodic reinforcement learning under which every relevant state-action pair has a nonzero...
  • GenDICE - GenDICE, short for Generalized stationary Distribution Correction Estimation, is a method for estimating distribution corrections from offline transition data.
  • Generative adversarial imitation learning - Generative adversarial imitation learning, or GAIL, learns a policy from expert demonstrations by training it against a discriminator.
  • Gradient bandit algorithm - A gradient bandit algorithm learns action preferences and converts them into action-selection probabilities, typically with a softmax function.
  • Gradient temporal-difference learning - Gradient temporal-difference learning refers to methods that estimate value functions by following gradients of carefully defined temporal-difference...
  • Greedy policy - A greedy policy chooses an action with the highest current estimated value at each decision point.

Sources

Nav2, Environmental Representation, costmaps and their use in global planning and local control: https://docs.nav2.org/rolling/getting_started/navigation_concepts/environmental_representation/

Nav2, Costmap 2D, official configuration documentation reached through the navigation guide: https://docs.nav2.org/rolling/configuration_and_development/configuration_guide/core_servers/costmap_2d/

The grid calculations and Elm Navigation case are original hypothetical illustrations. No specific deployment configuration is recommended.

Previous: Global constraint Next: Global file system

  • Home
  • Daily AI Updates
  • Blog
  • AIFBL Academy
  • AI Glossary
  • Products and Tools
  • Store
  • Free CFO AI Prompt Pack
  • About Shihan Sheriff
  • Privacy Policy
  • Terms of Use
  • Refund Policy
  • Cookie Policy
  • Earnings Disclaimer