Mattilsynet publishes their restaurant inspections on a REST service. This program loads the inspection data from the REST service and extacts the restaurants.
python restaurant2osm.py [filter][first inspection date]
All filters from the REST service are permitted, plus one extra filter for municipality. Examples:
- One municipality:
"kommune=Nes (Akershus)"
(include county name and "" if municipality name is not unique) - One postal code name:
"poststed=Vang på Hedmarken"
(include full name if not unique) - One postal code:
postnr=4885
- Restaurant name:
navn=Egon
(matches complete words only) - General queries:
query=Torvet
(matches complete words in any attribute, e.g. name and address) - Also combinations:
"query=Egon&poststed=Oslo"
(please include "")
The optional second parameter will produce restaurants with first inspection date on or after the given date. Format: 2019-10-15.
- Addresses are geocoded using the Kartverket REST service from the cadastral register
- Mattilsynet is using internal addresses, many of which are not correct or incomplete
- If no match, a few corrections are tried (removing abbreviations etc)
- Addresses which can not be geocoded to an exact location get a (0,0) coordinate and a GEOCODE tag. The output file may be processed further with geocode2osm to locate the missing addresses.
- Default tagging is amenity=restaurant. Some nodes get amenity=cafe, amenity=fast_food or shop=bakery based on their names. The tagging needs one by one verification.
- Restaurant names are not copy-edited - all names need to be manually verified.
- Some restaurants have a short lifespan. Please see the provided date for last inspection. Mattilsynet targets 12 months inspection intervals.
- Please see the provided date of creation or first inspection date to find the most recent/new restaurants.
- Please use the provided municipality or county to search for specific geographical areas.
- A ready to use OSM file is provided here.