### Python
```python
import requests
import os
import py7zr
url = "https://wxs.ign.fr/x02uy2aiwjo9bm8ce5plwqmr/telechargement/prepackage/ADMINEXPRESS-COG-CARTO_SHP_TERRITOIRES_PACK_2023-05-04$ADMIN-EXPRESS-COG-CARTO_3-2__SHP_LAMB93_FXX_2023-05-03/file/ADMIN-EXPRESS-COG-CARTO_3-2__SHP_LAMB93_FXX_2023-05-03.7z"
response = requests.get(url, stream = True)
with open("data.7z", "wb") as f:
f.write(response.content)
with py7zr.SevenZipFile('data.7z', mode='r') as z:
z.extractall()
def file_size(file_name):
file_stats = os.stat(file_name)
return f'File Size in MegaBytes is {file_stats.st_size / (1024 * 1024)}'
```
### CLI mapshaper
```python
sudo apt-get update
sudo apt install npm nodejs
git clone https://github.com/mbloch/mapshaper.git
cd mapshaper
npm install # install dependencies
npm run build # bundle source code files
sudo npm link # (optional) add global symlinks so scripts are available systemwide
mapshaper ADMIN-EXPRESS-COG-CARTO_3-2__SHP_LAMB93_FXX_2023-05-03/ADMIN-EXPRESS-COG-CARTO/1_DONNEES_LIVRAISON_2023-05-03/ADECOGC_3-2_SHP_LAMB93_FXX/COMMUNE.shp -filter '"69123,13055,75056".indexOf(INSEE_COM) > -1' invert -o out_cities.topojson
mapshaper ADMIN-EXPRESS-COG-CARTO_3-2__SHP_LAMB93_FXX_2023-05-03/ADMIN-EXPRESS-COG-CARTO/1_DONNEES_LIVRAISON_2023-05-03/ADECOGC_3-2_SHP_LAMB93_FXX/ARRONDISSEMENT_MUNICIPAL.shp -simplify 60% -o out_arrondissement.topojson
mapshaper out_cities.topojson out_arrondissement.topojson combine-files -merge-layers target=COMMUNE,ARRONDISSEMENT_MUNICIPAL force -rename-layers COMMUNE_ARRONDISSEMENT -simplify 60% -o test.topojson -proj from=wgs84
mapshaper ADMIN-EXPRESS-COG-CARTO_3-2__SHP_LAMB93_FXX_2023-05-03/ADMIN-EXPRESS-COG-CARTO/1_DONNEES_LIVRAISON_2023-05-03/ADECOGC_3-2_SHP_LAMB93_FXX/COMMUNE.shp name='' -split INSEE_REG -o 'regions/' format=geojson
```