: QGIS underwent massive API changes moving from version 2.x to 3.x. Ensure your PDF specifically covers QGIS 3 . Code written for QGIS 2 will fail immediately in QGIS 3 due to the migration from Python 2.7 to Python 3 and changes in the qgis.core architecture.

PyQGIS is the Python library that provides access to the QGIS API. It allows you to perform various GIS operations using Python scripts, from simply loading vector and raster data to creating complex standalone applications.

The PDF provides specific code blocks to initialize the QGIS application resources ( QgsApplication.initQgis() ) within a standard Python script.