diff --git a/exposurelib/database.py b/exposurelib/database.py index d4cc54a2a50c998516b0bc5aa3c2fe8dcd1e8c05..be59d250cc25a906bf7a1be7d0a3664b64565869 100644 --- a/exposurelib/database.py +++ b/exposurelib/database.py @@ -1521,8 +1521,8 @@ class SpatiaLiteExposure(SpatiaLiteDatabase, AbstractExposure): else: entity_id = self.insert_building_entity(quadkey, osm_id, geom_wkt)[0] self.insert_asset(entity_id, taxonomy_id, number, structural, night) - if asset_count + 1 % 10000 == 0: - logger.debug(f"{asset_count} assets imported") + if (asset_count + 1) % 10000 == 0: + logger.debug(f"{asset_count + 1} assets imported") self.connection.commit() self.connection.commit() logger.debug(f"""Entities and assets of the {input_model} model imported""") @@ -1766,8 +1766,8 @@ class SpatiaLiteExposure(SpatiaLiteDatabase, AbstractExposure): completeness if completeness else "NULL", geom_wkt, ) - if tile_count + 1 % 10000 == 0: - logger.debug(f"{tile_count} tiles imported") + if (tile_count + 1) % 10000 == 0: + logger.debug(f"{tile_count + 1} tiles imported") self.connection.commit() logger.debug("Tiles imported") self.connection.commit() @@ -1837,8 +1837,8 @@ class SpatiaLiteExposure(SpatiaLiteDatabase, AbstractExposure): self.insert_building( osm_id, quadkey, geom_wkt, occupancy=occupancy, stories=stories ) - if building_count + 1 % 10000 == 0: - logger.debug(f"{building_count} buildings imported") + if (building_count + 1) % 10000 == 0: + logger.debug(f"{building_count + 1} buildings imported") self.connection.commit() logger.debug("Buildings imported")