zoran-cuckovic / QGIS-visibility-analysis

Quantum GIS plugin for visibility analysis
GNU General Public License v3.0
72 stars 18 forks source link

Does Intervisibility Network work with two different input point layers? #24

Closed anitagraser closed 5 years ago

anitagraser commented 5 years ago

The user interface suggests that it is possible to use two different point layers as input for observer points and target points but the computation always fails if the input is not identical:

*1* Constructing the network
Traceback (most recent call last):
File "C:/Users/agraser/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ViewshedAnalysis\algorithms\viewshed_intervisibility.py", line 192, in processAlgorithm
o.network(t) #do this after .take which takes points within raster extents
File "C:/Users/agraser/AppData/Roaming/QGIS/QGIS3\profiles\default/python/plugins\ViewshedAnalysis\algorithms\modules\Points.py", line 380, in network
id2 = self.pt[pt2]["id"]
KeyError: 2
zoran-cuckovic commented 5 years ago

This is a bug, it should work with different files. I've fixed the problem in the experimental branch. I'll update the plugin in QGIS repository in short time.