Skip to content
This repository has been archived by the owner on Sep 20, 2021. It is now read-only.

Optimizing your routes

Malte edited this page May 2, 2021 · 1 revision

Improving your MAD routes

In this page I'm trying my best to organize all my knowledge about how scanning works and how to improve it, with the focus on optimizing your routes. It might sound overwhelming at first, but it's actually not that complicated. Just by running the faster-routes script you should already be able to easily shave off 20% off your Pokemon routes.

0. Enable do_nearby_scans in your MAD config

Right now, I have my open MAD PR#1120 that adds more ways to collect Pokemon data. If you're reading this and are coming from the future, you can just enable the do_nearby_scans flag. If you're from the present; The PR should be merged soon, so can just wait for that.

I highly recommend using redis cache with nearby scanning.

Either way, make sure to read the PR description before continuing here. It goes into much detail about the different types of Pokemon.

Everything here is written assuming these changes are active for you.

1. Understanding Pogo mechanics

Most stuff we're scanning is based on GMOs (GetMapObjects). GMOs contain much valuable data and are usually sent every 5 seconds. They contain a list of Level 15 S2 Cells, with each cell containing info about:

  • wild_pokemon: Mons within 70m of your location. No IVs, but correct locations and spawnpoint IDs
  • nearby_pokemon: Mons in a larger range. No IVs, correct location or spawnpoint IDs
  • forts: Gyms, Stops and everything that comes with them: Invasions, Raids, Lures, etc.

What you see in this picture is MADmin with Cellupdates enabled and a Mon route. In the settings I set the Mon visual radius to 510m. A green cell means that a recent GMO contained that cell. So as you can see, a GMO will always contain all cells that are within ~500m of your position. However, not all cells will contain all of the mentioned data. There's special rules for:

wild_pokemon

  • Sent within ~70m of your position
  • I'm not sure what cell level these are based on. So we usually calculate/edit routes based on every point contained within 67m
    • maybe it might be worth researching this and finding out how exactly we get wild mons

nearby_pokemon

I divide nearby_pokemon into 2 categories: nearby_stop and nearby_wild.

  • Each Level 15 cell can have a maximum of 6 nearby mons
  • If any Pokestop contained in the GMO has a Pokemon within ~50m of it, it's sent as a nearby_stop mon.
  • If a cell has less than 6 nearby_stop mons AND there's more Pokemon in it that are within a 200m range, you'll receive these as nearby_cell mons

Forts are sent within ~500m of your location. Below you can see a picture that visualized the different ranges.

A note on ranges

Ranges WILL vary per location. MAD is using hardcoded values that work everywhere in the world, but are probably lower than what would be correct for you. For example, the range I'm seeing cells in is around 510-520 meters, while MAD is using 490m to calculate raid_mitm routes. It's pretty easy to find out your correct range for forts by looking at MADmin, but for wild_mons and nearby_wild mons there's no good way to do this. Go look into it if you want to have perfectly optimized routes, but using MAD's default 67m and ~175m should be good for most cases.

MADmin tools

Unfortunately, MADmin is lacking a few features that would be cool for route optimizing, but there's some workarounds:

  • In the settings (gear icon) you can define a custom visual radius for mon routes
  • Enable Cellupdates to view Level 15 cells (If they don't show for a certain area, send a worker there and they should get updated)
  • Only mon routes can be edited on the map. So if you want an optimized raid route, it's best to create a temp mon route, edit that and copy the coordinates into a raid area
  • Of course you can enable Spawnpoints, Stops and Gyms when editing your routes. Cellupdates also show whether or not a worker saw a nearby_cell mon in them before.

Understanding nearby_cell_mode for mon_mitm areas

nearby_cell_mode can be set to True or False, by default it's False. It does 2 things:

  1. MAD's routcalc will be based on nearby cells, not spawns (useless for us - you should be creating your routes manually anyway)
  2. Usually, MAD will wait for nearby_pokemon instead of wild_pokemon

The second point being very important here: Sometimes, especially for bigger jumps, Pogo waits a bit before sending you the mons around you, while forts and nearby_pokemon are already in the GMOs. If turned off and there's no wild Pokemon around the player, MAD will wait a useless minute or two before throwing a timeout and continuing.

Are there points in your route that don't have encounters, just nearby pokemon or forts? Toggle nearby_cell_mode on. Else, toggle it off.

Route editing

faster-routes readme has some info about editing routes already, that can be applied to other routes as well:

  • MAD-calculated routes can usually be optimized by 20-40%. (which is huge)
  • ALWAYS edit your routes manually. This takes some time and focus but is 100% worth it. There's no algorithm that does a routecalc better than a human
  • Everything I write here is based on my personal goals with mapping: Scanning Unown and 100%IV relevant mons. I don't care about perfect IV common trash
  • When editing a route, make sure to enable other routes so you don't accidently cover duplicate areas

Mon routes

For optimizing mon routes I recommend the following workflow:

  • Install eventwatcher. If you've not been using eventwatcher for the past ~year, delete all spawns and re-init.
  • When running a new init, be generous with your fence and cover way more than what you intend to scan (it's 100% worth the extra wait)
  • Use madmin to delete old spawnpoints
  • Now calculate a base route using faster-routes
  • When the route is in madmin, set the mon visual radius to 67, show DEFAULT spawnpoints and edit it. Your goal will be to manually minimize overlap by deleting useless positions and moving others around.
  • You're also safe to ignore any geofence boundaries you previously set. Just try to cover as many spawnpoints as possible, even if they're slightly outside of your fence. If you see big clusters way outside of your fence, feel free to cover them as well.
  • You should try and aim for 30-40 routepoints per device for great DSTs. Up to 60 is also fine. Not more than 70-80.
  • Practice helps a lot. I edited my route like 3 or 4 times until I was satisfied with it and used other areas to practice by editing.

My main mon_mitm route

For the majority of my scan time, I used a 1000-point area calculated by MAD. In early 2021 I got that route down to ~630 points using the steps mentioned above. I then slowly expanded on it until I covered most of the town. When expanding, I had faster-routes calculate routes for the new parts, then copied the coordinates into the main area and then used overwrite_route.py on that list.

I now cover around 20-23km² with 931 routepoints. I have my walkers set so that all extra devices go there, so device amount always varies, but I'm usually getting 20-40 points per device.

The pink part is a "bonus" area. I'm just covering the main clusters there and ignore a bunch of solo spawnpoints. Usually, no one goes there, so it doesn't really matter.

The orange parts are extra locations I placed to cover cluster spawns.

Raid routes (or nearby routes for urban areas)

Probably overlooked by many, but with nearby mons, raid routes are great to cover huge areas. I had a 47-point MAD-calculated route that I got down to 35 points with manual editing. It covers around 70-100km² and gets me about 5000-6000 non-iv mons per hour. That's 5k mons/hour with 35 routepoints.

Here's the workflow I used:

  • Personally, I didn't use an init area, but that might have been a mistake. You should definitely try to run an init, even if it's a struggle for such big areas. I'll let no init slide if you've been doing quests there, since most Stop-Spawns should already be known this way
  • Enable Cellupdates, Stops, Gyms in MADmin. Set Mon visual route to 510m (maybe less or more for you)
  • Create small geofence there covering 1 or 2 spawnpoints, then let mad calculate a mon route with that fence
  • Use this mon route to build the raid route from ground up. It was just 35 points for me, so definitely doable. I was able to place the positions so they can also cover cluster spawns and/or good amount of cells sending nearby_cell mons. I was also able to cover most Stops, maybe even more than what MAD did with 12 addition positions.
  • In the center of your area, there's usually multiple good positions for a location, so try to start with the edge first, there it's usually clear what the best position for a routepoint is
  • When you're done, you can copy the coordinates from the area settings. You can then use Tabbomat's script to let the area run through ortools.
  • If you didn't run an init before, you might want to run a quick spawnpoint init for covered nearby_cell cells, so iv_mitm work well with them.

My route

There's another part to this route that didn't fit on the screenshot. Also, my devices are having a hiccup at the time of writing, so ignore that not all cells are green.

Nearby routes (for rural areas)

Note that this part was written based on false information about nearby_cell mons. I'm working on a better version of the route and will update this part later

I don't really recommend optimizing routes for nearby mons, but personally, they're good for me. I have a surplus of devices and live pretty rural. So this allows me to cover a huge area near me. I'm not 100% sure how many mons it gets me, but it's only a couple hundred per hour, maybe like 300-500.

Nearby optimized routes are very unique per area. Depending on your setup and priorities, you will have to think of good route setups yourself. My workflow looked like this:

  • Again, I also didn't run an init here but let me tell you it's 1000% worth it. Editing the route got soooo much easier after I did an init
  • Of course, be generous with the init. Pogo likes to put a bunch of spawns on random fields where absolutely no one would expect them
  • Then I enabled Cellupdates, Stops and DEFAULT Spawns and set the Mon visual radius to 180m
  • I drew a route in a way where it covers all cells with nearby_cell mons in them. I sometimes changed the visual radius to 70m or 510m to optimize IV scans and nearby_stop scans.
  • Within this area, I had one small "resort"/tourist destination thingy. It has a good amount of Stops and Spawns. So I first placed a few positions so that it covers as many stops and nearby_cells as possible and then used a few extra positions to roughly cover some bigger clusters.

My area

The "resort"

(the worker begins from the south-west, visual radius is 70m). Most stops and spawns are along the coast, so I placed some positions on land to cover all stops and nearby_cells and then put some extra locations along the coast.

More detailed part

This is an area with just a few stops. I cover as many nearby_cells with 180m as possible

The whole thing

  • It's hard to say how much area exactly I cover with this route, but just to give you a comparison: What you see on this screenshot is about ~250km².
  • I set the visual radius to 180m. That's what's covering nearby_cell mons. The green cells are what I would receive nearby_stop mons in
  • There's green cells on the screenshot not covered by the route, you can ignore that. But for comparison: The blue marked area is what I scan with 3 devices (180 routepoints). And that's just the cells it's updating - the actual mon areas are way smaller
  • The route has 52 points