voxcity 0.5.21__tar.gz → 0.5.23__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of voxcity might be problematic. Click here for more details.
- {voxcity-0.5.21 → voxcity-0.5.23}/PKG-INFO +4 -3
- {voxcity-0.5.21 → voxcity-0.5.23}/README.md +3 -2
- {voxcity-0.5.21 → voxcity-0.5.23}/docs/Makefile +18 -18
- {voxcity-0.5.21 → voxcity-0.5.23}/docs/conf.py +126 -152
- {voxcity-0.5.21 → voxcity-0.5.23}/docs/make.bat +36 -36
- {voxcity-0.5.21 → voxcity-0.5.23}/pyproject.toml +1 -1
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/exporter/envimet.py +10 -5
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/geoprocessor/utils.py +22 -35
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/simulator/solar.py +16 -12
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/utils/visualization.py +12 -12
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity.egg-info/PKG-INFO +4 -3
- voxcity-0.5.23/src/voxcity.egg-info/SOURCES.txt +50 -0
- voxcity-0.5.21/docs/_build/html/_images/08b3db000d7ff09f51e879d8e8a4bcba4b5e5ed59a9349b647881854bed4a7b1.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/16438e8e907bb04c1921588ef02b8ef9894fda4777c4215be17cb09de624b448.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/18bd5a56d075e7d84d503f169a971a9e366c04da141b7348822d463ebad5cf11.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/1d1d3a7e409cc572734a90449deb12629bc37de864fb9fcea1a2765e2d47ca55.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/2381f64d3b526db11e898baa6f8312fd0fffdc6d3dbd476f10eb8155fe528ec7.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/37ae1e201e9f8f1450d195ae004af51596fdbbffe1c127f8495ec87d3579770c.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/3c43ef4a707ae514837ea0202d122e3ac810695086726dad33589c15234aed70.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/4261120bd44487e132f79bddd3fbee9038582dbbd97bd707732d67839655cf14.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/4594a8ba7ca6906387b12cbc69ea87637648141d667e5f4ebb16c911cdc446bc.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/47ccb675b60d54c2200555b98251427524fc0480ff8ae1239dc69dad7ff582b8.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/487775ecc0a7ae2a17c33776a916217da35ed4d073cd9492a04c7b9abec7d883.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/4baaf8fe982e28474a1bc4ee0528709e8390f7a8f9dcdcbc7111411c27c40255.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/4d355ca695d3b477b0dc95f43a481b253c5e42dc774f8ce255e23d34862be447.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/4e6bcc86438ecca1bb265614a2a20d6d96a3b69c4ec3125c75ee6269025cfd15.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/55b2a97dd7e62dbfbff4a10f97c3b2c461763152e800b753b1f5ccd699fdf02f.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/5df41ef08d7317fa90a38b0ea19bcb2cf5c2f10ed05909f1ad158e25af1ef24d.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/793252d2628d9cae6b81fc90ab84ff1c474aeb7b8e15e74e06fbc1ceb6975ffd.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/8754f22f2f7153cf294fe603e8c60a3d93fc77cbabe9aae071fbcc2e4c7c9d9b.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/8b2deb89a4009b385747bdb66bdb49b92e5f1465cbf145b71150e81addb8a302.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/8cf83779f2069bd257b6db30ee99395605380de174a3ce6eddc74b35752d7c53.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/92d339bb67c3bd08896101d783f1e9db93e4e75b964c49279748305d8aa5b121.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/93648751c2dd2ea57a6ba8944d2f87cc6c8e9e81a1f4774f7da2f92b93a47423.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/93b19b81494eaf4ff4b17fad222b805977747025e9a5b5a008cf68777dbe9510.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/9f6eb35344a4492765ff2a655c9d1a7f5d26f947574a1ff8c62e5ec2e34c9d7d.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/9fe3565b796bbcfa9b8a6c68f2acc5215f85fb44e897309c70d872af642c4e2d.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/a16a92d7ff125fe3cc073defe75e38d086080239f3b021f0698cc4dedcc883e0.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/ab3ea52ae29974a354a21dccdc3de1dec76565a3fa196fbf3f9d21da62503cb4.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/b10ed6221adb54338ed45d8d2c0433b92d2780e78e91da57ca28b1caf2289fd2.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/b3062085f3602a261ceae8d98e804ef5cf616a2c340a47fd0417e8c9b305c4bb.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/b5aa8550d8f9a02146a09d679ed098ed0d685f524418fd6fd86faf54d3332bb3.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/b5af316dd59d7d3fa732e8f9672dab880a81d86f5d41e4a95d7ee767030d767e.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/b82ad5912e73c863733e461aa5d7be370c8328fc1168985011a510f3ebf347e1.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/c02b560b528c62b15debdcecbdb9e0ced88ee1e367b743de57fca9f7f0142a3b.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/c5ef47b292fdb2cf51f9b059eaff2c95e0df0f2a39f6c0f054fba95cd4a3d2fc.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/d78a3eb336be5ce5f77c495769998eebfff641eeabdb07cf096ba335ba384956.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/deb9b1005e47ff20de7df521c496b60387b0a7481fbce3b95c29cf0ed9326e62.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/e6e15d13dceb60233ecc9bc2aedd9e8df0b792a300896686a989a96dad59097a.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/ee526e0d726f8fe6a7e2ad3fd875a8d64de41d1bb3f8edcfffb7d9bdc83c51f4.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/f12f9703ddcc9120a5e13ad8a3524191355c9212ea8464846fd89ce0bd24c0ce.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/f90fcf8677590540881786f73264d464ddd26208acba82e72719ff14bbc3f766.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/f95baafd592f4cbc2240e7d3d2bd21c86be804fc8f20c589d8676e6502be8e49.png +0 -0
- voxcity-0.5.21/docs/_build/html/_images/ff225adaa3a89376e18d036337502ea61e01a52e11a2c335260c8506295936cd.png +0 -0
- voxcity-0.5.21/docs/_build/html/_static/file.png +0 -0
- voxcity-0.5.21/docs/_build/html/_static/minus.png +0 -0
- voxcity-0.5.21/docs/_build/html/_static/plus.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/08b3db000d7ff09f51e879d8e8a4bcba4b5e5ed59a9349b647881854bed4a7b1.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/16438e8e907bb04c1921588ef02b8ef9894fda4777c4215be17cb09de624b448.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/18bd5a56d075e7d84d503f169a971a9e366c04da141b7348822d463ebad5cf11.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/1d1d3a7e409cc572734a90449deb12629bc37de864fb9fcea1a2765e2d47ca55.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/2381f64d3b526db11e898baa6f8312fd0fffdc6d3dbd476f10eb8155fe528ec7.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/37ae1e201e9f8f1450d195ae004af51596fdbbffe1c127f8495ec87d3579770c.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/3c43ef4a707ae514837ea0202d122e3ac810695086726dad33589c15234aed70.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/4261120bd44487e132f79bddd3fbee9038582dbbd97bd707732d67839655cf14.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/4594a8ba7ca6906387b12cbc69ea87637648141d667e5f4ebb16c911cdc446bc.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/47ccb675b60d54c2200555b98251427524fc0480ff8ae1239dc69dad7ff582b8.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/487775ecc0a7ae2a17c33776a916217da35ed4d073cd9492a04c7b9abec7d883.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/4baaf8fe982e28474a1bc4ee0528709e8390f7a8f9dcdcbc7111411c27c40255.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/4d355ca695d3b477b0dc95f43a481b253c5e42dc774f8ce255e23d34862be447.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/4e6bcc86438ecca1bb265614a2a20d6d96a3b69c4ec3125c75ee6269025cfd15.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/55b2a97dd7e62dbfbff4a10f97c3b2c461763152e800b753b1f5ccd699fdf02f.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/5df41ef08d7317fa90a38b0ea19bcb2cf5c2f10ed05909f1ad158e25af1ef24d.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/793252d2628d9cae6b81fc90ab84ff1c474aeb7b8e15e74e06fbc1ceb6975ffd.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/8754f22f2f7153cf294fe603e8c60a3d93fc77cbabe9aae071fbcc2e4c7c9d9b.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/8b2deb89a4009b385747bdb66bdb49b92e5f1465cbf145b71150e81addb8a302.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/8cf83779f2069bd257b6db30ee99395605380de174a3ce6eddc74b35752d7c53.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/92d339bb67c3bd08896101d783f1e9db93e4e75b964c49279748305d8aa5b121.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/93648751c2dd2ea57a6ba8944d2f87cc6c8e9e81a1f4774f7da2f92b93a47423.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/93b19b81494eaf4ff4b17fad222b805977747025e9a5b5a008cf68777dbe9510.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/9f6eb35344a4492765ff2a655c9d1a7f5d26f947574a1ff8c62e5ec2e34c9d7d.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/9fe3565b796bbcfa9b8a6c68f2acc5215f85fb44e897309c70d872af642c4e2d.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/a16a92d7ff125fe3cc073defe75e38d086080239f3b021f0698cc4dedcc883e0.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/ab3ea52ae29974a354a21dccdc3de1dec76565a3fa196fbf3f9d21da62503cb4.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/b10ed6221adb54338ed45d8d2c0433b92d2780e78e91da57ca28b1caf2289fd2.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/b3062085f3602a261ceae8d98e804ef5cf616a2c340a47fd0417e8c9b305c4bb.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/b5aa8550d8f9a02146a09d679ed098ed0d685f524418fd6fd86faf54d3332bb3.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/b5af316dd59d7d3fa732e8f9672dab880a81d86f5d41e4a95d7ee767030d767e.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/b82ad5912e73c863733e461aa5d7be370c8328fc1168985011a510f3ebf347e1.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/c02b560b528c62b15debdcecbdb9e0ced88ee1e367b743de57fca9f7f0142a3b.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/c5ef47b292fdb2cf51f9b059eaff2c95e0df0f2a39f6c0f054fba95cd4a3d2fc.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/d78a3eb336be5ce5f77c495769998eebfff641eeabdb07cf096ba335ba384956.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/deb9b1005e47ff20de7df521c496b60387b0a7481fbce3b95c29cf0ed9326e62.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/e6e15d13dceb60233ecc9bc2aedd9e8df0b792a300896686a989a96dad59097a.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/ee526e0d726f8fe6a7e2ad3fd875a8d64de41d1bb3f8edcfffb7d9bdc83c51f4.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/f12f9703ddcc9120a5e13ad8a3524191355c9212ea8464846fd89ce0bd24c0ce.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/f90fcf8677590540881786f73264d464ddd26208acba82e72719ff14bbc3f766.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/f95baafd592f4cbc2240e7d3d2bd21c86be804fc8f20c589d8676e6502be8e49.png +0 -0
- voxcity-0.5.21/docs/_build/jupyter_execute/ff225adaa3a89376e18d036337502ea61e01a52e11a2c335260c8506295936cd.png +0 -0
- voxcity-0.5.21/docs/logo.png +0 -0
- voxcity-0.5.21/src/voxcity.egg-info/SOURCES.txt +0 -138
- {voxcity-0.5.21 → voxcity-0.5.23}/AUTHORS.rst +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/CONTRIBUTING.rst +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/HISTORY.rst +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/LICENSE +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/MANIFEST.in +0 -0
- {voxcity-0.5.21/docs/_build/html → voxcity-0.5.23/docs}/_static/logo.png +0 -0
- {voxcity-0.5.21/docs/_static → voxcity-0.5.23/docs}/logo.png +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/setup.cfg +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/__init__.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/__init__.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/citygml.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/eubucco.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/gee.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/mbfp.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/oemj.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/osm.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/overture.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/downloader/utils.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/exporter/__init__.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/exporter/magicavoxel.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/exporter/obj.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/generator.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/geoprocessor/__init__.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/geoprocessor/draw.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/geoprocessor/grid.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/geoprocessor/mesh.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/geoprocessor/network.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/geoprocessor/polygon.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/simulator/__init__.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/simulator/utils.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/simulator/view.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/utils/__init__.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/utils/lc.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/utils/material.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity/utils/weather.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity.egg-info/dependency_links.txt +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity.egg-info/requires.txt +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/src/voxcity.egg-info/top_level.txt +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/tests/__init__.py +0 -0
- {voxcity-0.5.21 → voxcity-0.5.23}/tests/voxelcity.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: voxcity
|
|
3
|
-
Version: 0.5.
|
|
3
|
+
Version: 0.5.23
|
|
4
4
|
Summary: voxcity is an easy and one-stop tool to output 3d city models for microclimate simulation by integrating multiple geospatial open-data
|
|
5
5
|
Author-email: Kunihiko Fujiwara <kunihiko@nus.edu.sg>
|
|
6
6
|
Maintainer-email: Kunihiko Fujiwara <kunihiko@nus.edu.sg>
|
|
@@ -64,10 +64,11 @@ Dynamic: license-file
|
|
|
64
64
|
[](https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing)
|
|
65
65
|
[](https://pypi.org/project/voxcity/)
|
|
66
66
|
[](https://pepy.tech/project/voxcity)
|
|
67
|
+
[](https://voxcity.readthedocs.io/en/latest/?badge=latest)
|
|
67
68
|
<!-- [](https://creativecommons.org/licenses/by-sa/4.0/) -->
|
|
68
69
|
|
|
69
70
|
<p align="center">
|
|
70
|
-
Tutorial preview: <a href="https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing">[Google Colab]</a>
|
|
71
|
+
Tutorial preview: <a href="https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing">[Google Colab]</a> | Documentation: <a href="https://voxcity.readthedocs.io/en/latest">[Read the Docs]</a>
|
|
71
72
|
</p>
|
|
72
73
|
|
|
73
74
|
<p align="center">
|
|
@@ -76,7 +77,7 @@ Dynamic: license-file
|
|
|
76
77
|
|
|
77
78
|
# VoxCity
|
|
78
79
|
|
|
79
|
-
**voxcity** is a Python package that provides a seamless solution for grid-based 3D city model generation and urban simulation for cities worldwide. VoxCity's generator module automatically downloads building heights, tree canopy heights, land cover, and terrain elevation within a specified target area, and voxelizes buildings, trees, land cover, and terrain to generate an integrated voxel city model. The simulator module enables users to conduct environmental simulations, including solar radiation and view index analyses. Users can export the generated models using several file formats compatible with external software, such as ENVI-met (INX), Blender, and Rhino (OBJ). Try it out using the [Google Colab Demo](https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing) or your local environment.
|
|
80
|
+
**voxcity** is a Python package that provides a seamless solution for grid-based 3D city model generation and urban simulation for cities worldwide. VoxCity's generator module automatically downloads building heights, tree canopy heights, land cover, and terrain elevation within a specified target area, and voxelizes buildings, trees, land cover, and terrain to generate an integrated voxel city model. The simulator module enables users to conduct environmental simulations, including solar radiation and view index analyses. Users can export the generated models using several file formats compatible with external software, such as ENVI-met (INX), Blender, and Rhino (OBJ). Try it out using the [Google Colab Demo](https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing) or your local environment. For detailed documentation, API reference, and tutorials, visit our [Read the Docs](https://voxcity.readthedocs.io/en/latest) page.
|
|
80
81
|
|
|
81
82
|
<!-- <p align="center">
|
|
82
83
|
<picture>
|
|
@@ -3,10 +3,11 @@
|
|
|
3
3
|
[](https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing)
|
|
4
4
|
[](https://pypi.org/project/voxcity/)
|
|
5
5
|
[](https://pepy.tech/project/voxcity)
|
|
6
|
+
[](https://voxcity.readthedocs.io/en/latest/?badge=latest)
|
|
6
7
|
<!-- [](https://creativecommons.org/licenses/by-sa/4.0/) -->
|
|
7
8
|
|
|
8
9
|
<p align="center">
|
|
9
|
-
Tutorial preview: <a href="https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing">[Google Colab]</a>
|
|
10
|
+
Tutorial preview: <a href="https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing">[Google Colab]</a> | Documentation: <a href="https://voxcity.readthedocs.io/en/latest">[Read the Docs]</a>
|
|
10
11
|
</p>
|
|
11
12
|
|
|
12
13
|
<p align="center">
|
|
@@ -15,7 +16,7 @@
|
|
|
15
16
|
|
|
16
17
|
# VoxCity
|
|
17
18
|
|
|
18
|
-
**voxcity** is a Python package that provides a seamless solution for grid-based 3D city model generation and urban simulation for cities worldwide. VoxCity's generator module automatically downloads building heights, tree canopy heights, land cover, and terrain elevation within a specified target area, and voxelizes buildings, trees, land cover, and terrain to generate an integrated voxel city model. The simulator module enables users to conduct environmental simulations, including solar radiation and view index analyses. Users can export the generated models using several file formats compatible with external software, such as ENVI-met (INX), Blender, and Rhino (OBJ). Try it out using the [Google Colab Demo](https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing) or your local environment.
|
|
19
|
+
**voxcity** is a Python package that provides a seamless solution for grid-based 3D city model generation and urban simulation for cities worldwide. VoxCity's generator module automatically downloads building heights, tree canopy heights, land cover, and terrain elevation within a specified target area, and voxelizes buildings, trees, land cover, and terrain to generate an integrated voxel city model. The simulator module enables users to conduct environmental simulations, including solar radiation and view index analyses. Users can export the generated models using several file formats compatible with external software, such as ENVI-met (INX), Blender, and Rhino (OBJ). Try it out using the [Google Colab Demo](https://colab.research.google.com/drive/1Lofd3RawKMr6QuUsamGaF48u2MN0hfrP?usp=sharing) or your local environment. For detailed documentation, API reference, and tutorials, visit our [Read the Docs](https://voxcity.readthedocs.io/en/latest) page.
|
|
19
20
|
|
|
20
21
|
<!-- <p align="center">
|
|
21
22
|
<picture>
|
|
@@ -1,19 +1,19 @@
|
|
|
1
|
-
# Minimal makefile for Sphinx documentation
|
|
2
|
-
|
|
3
|
-
# You can set these variables from the command line.
|
|
4
|
-
SPHINXOPTS =
|
|
5
|
-
SPHINXBUILD = python -msphinx
|
|
6
|
-
SPHINXPROJ = voxcity
|
|
7
|
-
SOURCEDIR = .
|
|
8
|
-
BUILDDIR = _build
|
|
9
|
-
|
|
10
|
-
# Put it first so that "make" without argument is like "make help".
|
|
11
|
-
help:
|
|
12
|
-
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
|
13
|
-
|
|
14
|
-
.PHONY: help Makefile
|
|
15
|
-
|
|
16
|
-
# Catch-all target: route all unknown targets to Sphinx using the new
|
|
17
|
-
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
|
|
18
|
-
%: Makefile
|
|
1
|
+
# Minimal makefile for Sphinx documentation
|
|
2
|
+
|
|
3
|
+
# You can set these variables from the command line.
|
|
4
|
+
SPHINXOPTS =
|
|
5
|
+
SPHINXBUILD = python -msphinx
|
|
6
|
+
SPHINXPROJ = voxcity
|
|
7
|
+
SOURCEDIR = .
|
|
8
|
+
BUILDDIR = _build
|
|
9
|
+
|
|
10
|
+
# Put it first so that "make" without argument is like "make help".
|
|
11
|
+
help:
|
|
12
|
+
@$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
|
13
|
+
|
|
14
|
+
.PHONY: help Makefile
|
|
15
|
+
|
|
16
|
+
# Catch-all target: route all unknown targets to Sphinx using the new
|
|
17
|
+
# "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
|
|
18
|
+
%: Makefile
|
|
19
19
|
@$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
|
|
@@ -1,152 +1,126 @@
|
|
|
1
|
-
# Configuration file for the Sphinx documentation builder.
|
|
2
|
-
#
|
|
3
|
-
# This file only contains a selection of the most common options. For a full
|
|
4
|
-
# list see the documentation:
|
|
5
|
-
# https://www.sphinx-doc.org/en/master/usage/configuration.html
|
|
6
|
-
|
|
7
|
-
# -- Project information -----------------------------------------------------
|
|
8
|
-
|
|
9
|
-
project = "voxcity"
|
|
10
|
-
copyright = "2024, Kunihiko Fujiwara"
|
|
11
|
-
author = "Kunihiko Fujiwara"
|
|
12
|
-
|
|
13
|
-
# -- General configuration ---------------------------------------------------
|
|
14
|
-
|
|
15
|
-
# Add any Sphinx extension module names here, as strings. They can be
|
|
16
|
-
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
|
17
|
-
# ones.
|
|
18
|
-
nbsphinx_execute = "never"
|
|
19
|
-
|
|
20
|
-
extensions = [
|
|
21
|
-
"myst_nb",
|
|
22
|
-
"autoapi.extension",
|
|
23
|
-
"sphinx.ext.napoleon",
|
|
24
|
-
"sphinx.ext.viewcode",
|
|
25
|
-
"sphinxcontrib.bibtex",
|
|
26
|
-
]
|
|
27
|
-
|
|
28
|
-
# Add these lines to configure myst-nb
|
|
29
|
-
nb_execution_mode = "off"
|
|
30
|
-
|
|
31
|
-
#
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
#
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
#
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
#
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
"
|
|
95
|
-
"
|
|
96
|
-
"
|
|
97
|
-
"
|
|
98
|
-
"
|
|
99
|
-
"
|
|
100
|
-
"
|
|
101
|
-
"
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
"
|
|
105
|
-
"
|
|
106
|
-
"
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
return True
|
|
128
|
-
if what == "class" and any(cls in name for cls in skip_classes):
|
|
129
|
-
return True
|
|
130
|
-
if any(keyword in name for keyword in skip_keywords):
|
|
131
|
-
return True
|
|
132
|
-
if what == "attribute":
|
|
133
|
-
return True
|
|
134
|
-
|
|
135
|
-
return skip
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
def setup(app):
|
|
139
|
-
app.connect("autoapi-skip-member", skip_util_classes)
|
|
140
|
-
app.add_config_value(
|
|
141
|
-
"recommonmark_config",
|
|
142
|
-
{
|
|
143
|
-
"auto_toc_tree_section": "Contents",
|
|
144
|
-
"enable_eval_rst": True,
|
|
145
|
-
},
|
|
146
|
-
True,
|
|
147
|
-
)
|
|
148
|
-
app.add_transform(AutoStructify)
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
# Add this new import at the top of the file
|
|
152
|
-
from recommonmark.transform import AutoStructify
|
|
1
|
+
# Configuration file for the Sphinx documentation builder.
|
|
2
|
+
#
|
|
3
|
+
# This file only contains a selection of the most common options. For a full
|
|
4
|
+
# list see the documentation:
|
|
5
|
+
# https://www.sphinx-doc.org/en/master/usage/configuration.html
|
|
6
|
+
|
|
7
|
+
# -- Project information -----------------------------------------------------
|
|
8
|
+
|
|
9
|
+
project = "voxcity"
|
|
10
|
+
copyright = "2024, Kunihiko Fujiwara"
|
|
11
|
+
author = "Kunihiko Fujiwara"
|
|
12
|
+
|
|
13
|
+
# -- General configuration ---------------------------------------------------
|
|
14
|
+
|
|
15
|
+
# Add any Sphinx extension module names here, as strings. They can be
|
|
16
|
+
# extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
|
|
17
|
+
# ones.
|
|
18
|
+
nbsphinx_execute = "never"
|
|
19
|
+
|
|
20
|
+
extensions = [
|
|
21
|
+
"myst_nb",
|
|
22
|
+
"autoapi.extension",
|
|
23
|
+
"sphinx.ext.napoleon",
|
|
24
|
+
"sphinx.ext.viewcode",
|
|
25
|
+
"sphinxcontrib.bibtex",
|
|
26
|
+
]
|
|
27
|
+
|
|
28
|
+
# Add these lines to configure myst-nb
|
|
29
|
+
nb_execution_mode = "off"
|
|
30
|
+
|
|
31
|
+
# Bibtex settings
|
|
32
|
+
bibtex_bibfiles = ["references.bib"]
|
|
33
|
+
bibtex_default_style = "plain"
|
|
34
|
+
autoapi_dirs = ["../src"]
|
|
35
|
+
|
|
36
|
+
autoapi_options = [
|
|
37
|
+
"members",
|
|
38
|
+
"undoc-members",
|
|
39
|
+
"show-inheritance",
|
|
40
|
+
"imported-members",
|
|
41
|
+
"special-members",
|
|
42
|
+
# "private-members",
|
|
43
|
+
"inherited-members",
|
|
44
|
+
"show-module-summary",
|
|
45
|
+
]
|
|
46
|
+
|
|
47
|
+
autoapi_own_page_level = "class"
|
|
48
|
+
# List of patterns, relative to source directory, that match files and
|
|
49
|
+
# directories to ignore when looking for source files.
|
|
50
|
+
# This pattern also affects html_static_path and html_extra_path.
|
|
51
|
+
exclude_patterns = ["_build", "Thumbs.db", ".DS_Store"]
|
|
52
|
+
|
|
53
|
+
# -- Options for HTML output -------------------------------------------------
|
|
54
|
+
|
|
55
|
+
# The theme to use for HTML and HTML Help pages. See the documentation for
|
|
56
|
+
# a list of builtin themes.
|
|
57
|
+
html_theme = "furo"
|
|
58
|
+
|
|
59
|
+
# Theme options are theme-specific and customize the look and feel of a theme
|
|
60
|
+
# further. For a list of options available for each theme, see the
|
|
61
|
+
# documentation.
|
|
62
|
+
html_theme_options = {
|
|
63
|
+
"sidebar_hide_name": False,
|
|
64
|
+
"navigation_with_keys": True,
|
|
65
|
+
# "announcement": "This is a beta version of the documentation.",
|
|
66
|
+
"light_logo": "logo.png",
|
|
67
|
+
"dark_logo": "logo.png",
|
|
68
|
+
}
|
|
69
|
+
|
|
70
|
+
html_title = "VoxCity Documentation"
|
|
71
|
+
# Remove or comment out the following line:
|
|
72
|
+
# html_logo = "logo.png"
|
|
73
|
+
html_favicon = "_static/favicon.ico" # Make sure you have a favicon file
|
|
74
|
+
|
|
75
|
+
# Add these lines near the other html_* configurations
|
|
76
|
+
html_static_path = ["_static"]
|
|
77
|
+
html_css_files = ["custom.css"]
|
|
78
|
+
|
|
79
|
+
def skip_util_classes(app, what, name, obj, skip, options):
|
|
80
|
+
skip_packages = [
|
|
81
|
+
"mapillary",
|
|
82
|
+
"kartaview",
|
|
83
|
+
"classification",
|
|
84
|
+
"segmentation",
|
|
85
|
+
"low_level",
|
|
86
|
+
"depth_estimation",
|
|
87
|
+
"embeddings",
|
|
88
|
+
"object_detection"
|
|
89
|
+
]
|
|
90
|
+
skip_modules = [
|
|
91
|
+
"base",
|
|
92
|
+
"font_property",
|
|
93
|
+
"gsv",
|
|
94
|
+
"ams",
|
|
95
|
+
"mly",
|
|
96
|
+
"kv",
|
|
97
|
+
"depth_estimation",
|
|
98
|
+
"embeddings",
|
|
99
|
+
"mly_metadata",
|
|
100
|
+
"image_to_pointcloud",
|
|
101
|
+
"transform_image",
|
|
102
|
+
"hist",
|
|
103
|
+
"image",
|
|
104
|
+
"kde",
|
|
105
|
+
"map",
|
|
106
|
+
"config"
|
|
107
|
+
]
|
|
108
|
+
skip_classes = ["ImageDataset", "GSVDownloader", "Logger"]
|
|
109
|
+
skip_keywords = ["utils", "torchhub", "zoedepth", "depth_anything", "dinov2"]
|
|
110
|
+
|
|
111
|
+
if what == "package" and any(pkg in name for pkg in skip_packages):
|
|
112
|
+
return True
|
|
113
|
+
if what == "module" and any(mod in name for mod in skip_modules):
|
|
114
|
+
return True
|
|
115
|
+
if what == "class" and any(cls in name for cls in skip_classes):
|
|
116
|
+
return True
|
|
117
|
+
if any(keyword in name for keyword in skip_keywords):
|
|
118
|
+
return True
|
|
119
|
+
if what == "attribute":
|
|
120
|
+
return True
|
|
121
|
+
|
|
122
|
+
return skip
|
|
123
|
+
|
|
124
|
+
|
|
125
|
+
def setup(app):
|
|
126
|
+
app.connect("autoapi-skip-member", skip_util_classes)
|
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
@ECHO OFF
|
|
2
|
-
|
|
3
|
-
pushd %~dp0
|
|
4
|
-
|
|
5
|
-
REM Command file for Sphinx documentation
|
|
6
|
-
|
|
7
|
-
if "%SPHINXBUILD%" == "" (
|
|
8
|
-
set SPHINXBUILD=python -msphinx
|
|
9
|
-
)
|
|
10
|
-
set SOURCEDIR=.
|
|
11
|
-
set BUILDDIR=_build
|
|
12
|
-
set SPHINXPROJ=voxcity
|
|
13
|
-
|
|
14
|
-
if "%1" == "" goto help
|
|
15
|
-
|
|
16
|
-
%SPHINXBUILD% >NUL 2>NUL
|
|
17
|
-
if errorlevel 9009 (
|
|
18
|
-
echo.
|
|
19
|
-
echo.The Sphinx module was not found. Make sure you have Sphinx installed,
|
|
20
|
-
echo.then set the SPHINXBUILD environment variable to point to the full
|
|
21
|
-
echo.path of the 'sphinx-build' executable. Alternatively you may add the
|
|
22
|
-
echo.Sphinx directory to PATH.
|
|
23
|
-
echo.
|
|
24
|
-
echo.If you don't have Sphinx installed, grab it from
|
|
25
|
-
echo.http://sphinx-doc.org/
|
|
26
|
-
exit /b 1
|
|
27
|
-
)
|
|
28
|
-
|
|
29
|
-
%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS%
|
|
30
|
-
goto end
|
|
31
|
-
|
|
32
|
-
:help
|
|
33
|
-
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS%
|
|
34
|
-
|
|
35
|
-
:end
|
|
36
|
-
popd
|
|
1
|
+
@ECHO OFF
|
|
2
|
+
|
|
3
|
+
pushd %~dp0
|
|
4
|
+
|
|
5
|
+
REM Command file for Sphinx documentation
|
|
6
|
+
|
|
7
|
+
if "%SPHINXBUILD%" == "" (
|
|
8
|
+
set SPHINXBUILD=python -msphinx
|
|
9
|
+
)
|
|
10
|
+
set SOURCEDIR=.
|
|
11
|
+
set BUILDDIR=_build
|
|
12
|
+
set SPHINXPROJ=voxcity
|
|
13
|
+
|
|
14
|
+
if "%1" == "" goto help
|
|
15
|
+
|
|
16
|
+
%SPHINXBUILD% >NUL 2>NUL
|
|
17
|
+
if errorlevel 9009 (
|
|
18
|
+
echo.
|
|
19
|
+
echo.The Sphinx module was not found. Make sure you have Sphinx installed,
|
|
20
|
+
echo.then set the SPHINXBUILD environment variable to point to the full
|
|
21
|
+
echo.path of the 'sphinx-build' executable. Alternatively you may add the
|
|
22
|
+
echo.Sphinx directory to PATH.
|
|
23
|
+
echo.
|
|
24
|
+
echo.If you don't have Sphinx installed, grab it from
|
|
25
|
+
echo.http://sphinx-doc.org/
|
|
26
|
+
exit /b 1
|
|
27
|
+
)
|
|
28
|
+
|
|
29
|
+
%SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS%
|
|
30
|
+
goto end
|
|
31
|
+
|
|
32
|
+
:help
|
|
33
|
+
%SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS%
|
|
34
|
+
|
|
35
|
+
:end
|
|
36
|
+
popd
|
|
@@ -386,12 +386,17 @@ def create_xml_content(building_height_grid, building_id_grid, land_cover_veg_gr
|
|
|
386
386
|
r = (100 + verticalStretch) / 100 # Growth ratio
|
|
387
387
|
S_target = (int(np.max(building_on_dem_grid)/meshsize + 0.5) * meshsize) * (domain_building_max_height_ratio - 1)
|
|
388
388
|
min_n = find_min_n(a, r, S_target, max_n=1000000)
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
389
|
+
if min_n is None:
|
|
390
|
+
# Fallback to non-telescoping grid if calculation fails
|
|
391
|
+
print("Warning: Telescoping grid calculation failed, using uniform grid")
|
|
392
|
+
grids_Z = max(int(np.max(building_on_dem_grid)/meshsize + 0.5) * domain_building_max_height_ratio, min_grids_Z)
|
|
393
393
|
else:
|
|
394
|
-
|
|
394
|
+
grids_Z_tent = int(np.max(building_on_dem_grid)/meshsize + 0.5) + min_n
|
|
395
|
+
if grids_Z_tent < min_grids_Z:
|
|
396
|
+
grids_Z = min_grids_Z
|
|
397
|
+
startStretch += (min_grids_Z - grids_Z)
|
|
398
|
+
else:
|
|
399
|
+
grids_Z = grids_Z_tent
|
|
395
400
|
else:
|
|
396
401
|
# Calculate vertical grid cells without telescoping
|
|
397
402
|
grids_Z = max(int(np.max(building_on_dem_grid)/meshsize + 0.5) * domain_building_max_height_ratio, min_grids_Z)
|
|
@@ -524,7 +524,7 @@ def get_city_country_name_from_rectangle(coordinates):
|
|
|
524
524
|
center_coord = (center_lat, center_lon)
|
|
525
525
|
|
|
526
526
|
# Initialize geocoder with rate limiting to avoid hitting API limits
|
|
527
|
-
geolocator = Nominatim(user_agent="
|
|
527
|
+
geolocator = Nominatim(user_agent="your_app_name (your_email@example.com)")
|
|
528
528
|
reverse = RateLimiter(geolocator.reverse, min_delay_seconds=2, error_wait_seconds=5, max_retries=3)
|
|
529
529
|
|
|
530
530
|
try:
|
|
@@ -537,11 +537,10 @@ def get_city_country_name_from_rectangle(coordinates):
|
|
|
537
537
|
country = address.get('country', '')
|
|
538
538
|
return f"{city}/ {country}"
|
|
539
539
|
else:
|
|
540
|
-
print("Location not found
|
|
540
|
+
print("Location not found")
|
|
541
541
|
return "Unknown Location/ Unknown Country"
|
|
542
542
|
except Exception as e:
|
|
543
543
|
print(f"Error retrieving location for {center_coord}: {e}")
|
|
544
|
-
print("Using fallback value")
|
|
545
544
|
return "Unknown Location/ Unknown Country"
|
|
546
545
|
|
|
547
546
|
def get_timezone_info(rectangle_coords):
|
|
@@ -573,39 +572,27 @@ def get_timezone_info(rectangle_coords):
|
|
|
573
572
|
center_lon = sum(longitudes) / len(longitudes)
|
|
574
573
|
center_lat = sum(latitudes) / len(latitudes)
|
|
575
574
|
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
return utc_offset, timezone_longitude_str
|
|
594
|
-
else:
|
|
595
|
-
# Fallback: estimate timezone from longitude
|
|
596
|
-
print("Timezone not found, estimating from longitude")
|
|
597
|
-
estimated_offset = center_lon / 15 # Rough estimation: 15 degrees per hour
|
|
598
|
-
utc_offset = f"UTC{estimated_offset:+.2f}"
|
|
599
|
-
timezone_longitude_str = f"{center_lon:.5f}"
|
|
600
|
-
return utc_offset, timezone_longitude_str
|
|
601
|
-
except Exception as e:
|
|
602
|
-
print(f"Error retrieving timezone for {center_lon}, {center_lat}: {e}")
|
|
603
|
-
print("Using fallback timezone values")
|
|
604
|
-
# Fallback values
|
|
605
|
-
estimated_offset = center_lon / 15
|
|
606
|
-
utc_offset = f"UTC{estimated_offset:+.2f}"
|
|
607
|
-
timezone_longitude_str = f"{center_lon:.5f}"
|
|
575
|
+
# Find timezone at center coordinates
|
|
576
|
+
tf = TimezoneFinder()
|
|
577
|
+
timezone_str = tf.timezone_at(lng=center_lon, lat=center_lat)
|
|
578
|
+
|
|
579
|
+
if timezone_str:
|
|
580
|
+
# Get current time in local timezone to calculate offset
|
|
581
|
+
timezone = pytz.timezone(timezone_str)
|
|
582
|
+
now = datetime.now(timezone)
|
|
583
|
+
offset_seconds = now.utcoffset().total_seconds()
|
|
584
|
+
offset_hours = offset_seconds / 3600
|
|
585
|
+
|
|
586
|
+
# Format timezone offset and calculate central meridian
|
|
587
|
+
utc_offset = f"UTC{offset_hours:+.2f}"
|
|
588
|
+
timezone_longitude = offset_hours * 15 # Each hour offset = 15 degrees longitude
|
|
589
|
+
timezone_longitude_str = f"{timezone_longitude:.5f}"
|
|
590
|
+
|
|
608
591
|
return utc_offset, timezone_longitude_str
|
|
592
|
+
else:
|
|
593
|
+
# Return fallback values if timezone cannot be determined
|
|
594
|
+
print("Warning: Timezone not found for the given location, using UTC+00:00")
|
|
595
|
+
return "UTC+00:00", "0.00000"
|
|
609
596
|
|
|
610
597
|
def validate_polygon_coordinates(geometry):
|
|
611
598
|
"""
|
|
@@ -1341,11 +1341,12 @@ def get_building_solar_irradiance(
|
|
|
1341
1341
|
# # Optional OBJ export
|
|
1342
1342
|
# obj_export = kwargs.get("obj_export", False)
|
|
1343
1343
|
# if obj_export:
|
|
1344
|
-
#
|
|
1345
|
-
#
|
|
1346
|
-
#
|
|
1347
|
-
|
|
1348
|
-
#
|
|
1344
|
+
# # Get export parameters
|
|
1345
|
+
# output_dir = kwargs.get("output_directory", "output")
|
|
1346
|
+
# output_file_name = kwargs.get("output_file_name", "solar_irradiance")
|
|
1347
|
+
|
|
1348
|
+
# # Export the mesh directly
|
|
1349
|
+
# irradiance_mesh.export(f"{output_dir}/{output_file_name}.obj")
|
|
1349
1350
|
|
|
1350
1351
|
return irradiance_mesh
|
|
1351
1352
|
|
|
@@ -1426,6 +1427,8 @@ def get_cumulative_building_solar_irradiance(
|
|
|
1426
1427
|
face_cum_global = np.zeros(n_faces, dtype=np.float64)
|
|
1427
1428
|
|
|
1428
1429
|
boundary_mask = None
|
|
1430
|
+
instant_kwargs = kwargs.copy()
|
|
1431
|
+
instant_kwargs['obj_export'] = False
|
|
1429
1432
|
|
|
1430
1433
|
# Iterate over each timestep
|
|
1431
1434
|
for idx, (time_utc, row) in enumerate(df_period_utc.iterrows()):
|
|
@@ -1450,7 +1453,7 @@ def get_cumulative_building_solar_irradiance(
|
|
|
1450
1453
|
DNI,
|
|
1451
1454
|
DHI,
|
|
1452
1455
|
show_plot=False, # or any other flags
|
|
1453
|
-
**
|
|
1456
|
+
**instant_kwargs
|
|
1454
1457
|
)
|
|
1455
1458
|
|
|
1456
1459
|
# Extract arrays
|
|
@@ -1488,14 +1491,15 @@ def get_cumulative_building_solar_irradiance(
|
|
|
1488
1491
|
|
|
1489
1492
|
cumulative_mesh.name = "Cumulative Solar Irradiance (Wh/m²)"
|
|
1490
1493
|
|
|
1491
|
-
# Optional export
|
|
1494
|
+
# # Optional OBJ export
|
|
1492
1495
|
# obj_export = kwargs.get("obj_export", False)
|
|
1493
1496
|
# if obj_export:
|
|
1494
|
-
#
|
|
1495
|
-
#
|
|
1496
|
-
#
|
|
1497
|
-
|
|
1498
|
-
#
|
|
1497
|
+
# # Get export parameters
|
|
1498
|
+
# output_dir = kwargs.get("output_directory", "output")
|
|
1499
|
+
# output_file_name = kwargs.get("output_file_name", "solar_irradiance")
|
|
1500
|
+
|
|
1501
|
+
# # Export the mesh directly
|
|
1502
|
+
# irradiance_mesh.export(f"{output_dir}/{output_file_name}.obj")
|
|
1499
1503
|
|
|
1500
1504
|
return cumulative_mesh
|
|
1501
1505
|
|