Current location - Education and Training Encyclopedia - University ranking - Using Python Drawing Tool-Leaf Introduction
Using Python Drawing Tool-Leaf Introduction
1. Ready

Some friends may not have used lyum, but it is actually a third-party library for professional mapping in python, which needs to be installed before it can be used.

After the installation, we can demonstrate the following in jupyterlab:

For the above output, it is actually an interactive map, which supports zooming in and dragging abbreviations and so on.

If you want to store the output locally, you can do this:

You can see that this file is saved locally, and you can open a browser for interactive operation.

The above is an ordinary process. ......

2. About leaves. Map ()

In the last part, we can see that this map gadget is directly a map. Here we will introduce several commonly used parameters.

So many parameters! !

The above are some commonly used parameters, the most commonly used are location, zoom_start and tiles.

There are several built-in map styles:

Let's simply try the location and zoo_start parameters:

You can see the Tsinghua University campus.

The parameters of the map are briefly introduced above. Next, let's take a look at the choice of map basemap style ~

3. Built-in map basemap style

We see that leav actually has several built-in map basemap styles, and some of them need to apply for key, so we won't give a demonstration here because we didn't apply successfully.

Topographic base map

Black and white unmarked basemap

Ink painting base map

The above are some demonstrations of the built-in map basemap style. Some people who need keys can go to this website to apply:

In addition, you can also find some maps here.

I will also study these map basemap styles in the future and try to share more interesting maps with you.

Of course, the maps we use more in China are those of Gaode, Baidu and Tencent. Next, let's play!

4. Various third-party map basemap styles

Here I will demonstrate Gaode map, Zhitu GeoQ and Tencent map.

Chinese and English maps, satellite images, street maps and conventional maps of Gaode map.

Chinese and English maps

Pure English map

Satellite image map

Street map

Schematic diagram

Anyway, I think this is good and easy to use.

Multi-style map, available at any time.

colour disk

Warm color plate

Grey edition

Blue-black edition

English edition

Chinese administrative division border

Special topic of water system

Street network diagram

Warm street network diagram

You need to register a key.

Sky map image

Notes on sky map images

Sky map vector

Vector labeling of sky map

Sky map topography

Topographic annotation of sky map

Baidu map failed in my test here, and no suitable substitute has been found for the time being.

supplement

In fact, we can find more URLs of map basemap slices to replace and enrich our map drawing.

In addition, when you draw a map with latitude and longitude coordinates, such as marking points, drawing areas, drawing heat maps, etc. You need to consider which map system the latitude and longitude coordinates belong to, and then use the relevant basemap of the corresponding map system for accurate drawing!