[QGIS-Developer] Will the resource sharing plugin be ported to a core plugin? Or or similar functionality implemented?

2019-06-05 Thread Áron Gergely

Hi Developers list,

A long time user, budding contributor here. Thanks so much for building 
QGIS to what it is today! :)


Does anyone know whether it is a plan to port the QGIS Resource Sharing 
plugin to a core plugin?


I have read a mention of this among the issues+comments on the plugin's 
github, see here:

https://github.com/akbargumbira/qgis_resources_sharing/issues/51#issuecomment-344397441

I have asked the developer of the plugin a while ago but received no 
response. I thought perhaps someone here knows whether this is (was) 
indeed the plan?
Otherwise, would there be a plan to implement its functionality? And if 
so, do you need help doing that?


Best Regards,
Áron Gergely
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Will the resource sharing plugin be ported to a core plugin? Or or similar functionality implemented?

2019-06-05 Thread Áron Gergely


Thank you for Alessandro!

I am aware of the plugin being available in QGIS 3 -  I am just 
exploring possibilities.


We are looking to create a plugin that would use external resources
to create map layouts.

Then the current solution is either replicating the functionality of the 
resource sharing plugin or instructing the users to get the resources 
via the resource sharing plugin.


...or finding a way to embed these resources in the project file.

Thanks again,

Best regards,
Aron Gergely


On 05/06/2019 13:57, Alessandro Pasotti wrote:


On Wed, Jun 5, 2019 at 1:33 PM Áron Gergely <mailto:aron.gerg...@rasterra.nl>> wrote:


Hi Developers list,

A long time user, budding contributor here. Thanks so much for
building
QGIS to what it is today! :)

Does anyone know whether it is a plan to port the QGIS Resource
Sharing
plugin to a core plugin?


Hi, that was indeed the original plan.

But some developers raised general concerns against including other 
plugins in the core, that's why the idea was abandoned.


The plugin has been ported to  QGIS 3 a few months ago, so it is now 
available.




I have read a mention of this among the issues+comments on the
plugin's
github, see here:

https://github.com/akbargumbira/qgis_resources_sharing/issues/51#issuecomment-344397441

I have asked the developer of the plugin a while ago but received no
response. I thought perhaps someone here knows whether this is (was)
indeed the plan?
Otherwise, would there be a plan to implement its functionality?
And if
so, do you need help doing that?

    Best Regards,
Áron Gergely
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org <mailto:QGIS-Developer@lists.osgeo.org>
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer



--
Alessandro Pasotti
w3: www.itopen.it <http://www.itopen.it>


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] saving a layer with the world_map.shp

2019-06-07 Thread Áron Gergely

Hi Tim,

With Raymond we are planning on using your great ester egg data in the 
overview box within map layouts.
I am looking for the license of the data,  do you perhaps know it / know 
where to find it?

Or does it fall under QGIS' license?

Thanks,

Best Regards,
Aron Gergely

I am also a fan of the ester egg, learned it from Raymond.

On 28/05/2019 10:50, Tim Sutton wrote:

Hi

I don’t have any immediate fix for your issue, but I am glad you are 
enjoying my Easter egg :-) I also use it ALL THE TIME and it is really 
great in training courses etc. to get people quickly started with 
panning and zooming or putting their data in context. One day maybe we 
can elevate it’s status to have a button on the file toolbar that adds 
it to the canvas without the need for bunnies and chocolate :-)


PS for those that don’t know about the Easter egg, type ‘world’ into 
the coordinate box in the status bar as shown below, then press ENTER.


Regards

Tim

On 27 May 2019, at 14:58, Raymond Nijssen > wrote:


I know it was introduced as an easter egg, but I'm very happy with 
the built in world map in qgis. I'm using it in a plugin to 
automatically add a layer for the overview map in my layout. This 
layer points to a shapefile in my qgis install directory:


/home/raymond/programs/qgis-master/share/qgis/resources/data/world_map.shp

Now, when saving my project and somebody else opening it, the layer 
is invalid (of course). Is there a way to make the project point to 
the right file, using some kind of variable pointing to the qgis 
installation path?


like this:
{QGIS_RESOURCE_PATH}/data/world_map.shp

or I could copy the world.shp into my plugin and do this:

{QGIS_PLUGIN_PATH}/my-plugin/data/world_map.shp

These paths should then be saved including the variable in the 
project file.




Another option would be to save the shp-file in the .qgz somehow but 
I'm not too sure if that is the way to go..




This is the way I create the path now:

worldShp = os.path.join(QgsApplication.pkgDataPath(), 'resources', 
'data', 'world_map.shp')




To make the question more general, is it possible to add resources to 
a plugin in a way that projects point to these resources and make 
that work for other users too?



Hope anyone can help!

Kind regards,
Raymond


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org 
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


—








*Tim Sutton*

*Co-founder:*Kartoza
*Ex Project chair:*QGIS.org 

Visit http://kartoza.com  to find out about open 
source:


Desktop GIS programming services
Geospatial web development
GIS Training
Consulting Services

*Skype*: timlinux
*IRC:*timlinux on #qgis at freenode.net 

I'd love to connect. Here's my calendar link 
 to make finding time easy.



___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] saving a layer with the world_map.shp

2019-07-01 Thread Áron Gergely

Hi Matthias,

Yes of course. In fact I have already done it for a plugin that I work 
together on with Raymond.
I used the same world_map.shp and also saved the styling into the same 
geopackage as the default style.


Thus happy to proceed forward with this.

Best regards,
Aron

On 01/07/2019 13:24, arongergely wrote:

Hi,

Nathan and Tim, thanks for helping to track down the data source!

I was wondering, if this easter egg was used a lot for trainings, testing,
etc,
wouldn't it be better in the future to swap the shape file for a GeoPackage?

That could also lend itself as a container of other generalized world data
together with their QML/SLD stylings,
such as points for capital cities.

Right now it seems to me like a good idea but perhaps you can correct me. :)

Best Regards,
Aron



--
Sent from: http://osgeo-org.1560.x6.nabble.com/QGIS-Developer-f4099106.html
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

[QGIS-Developer] Difficulties with custom bad layer handler in plugin code

2019-07-21 Thread Áron Gergely

Hello to all contributors,

I am trying to implement a custom bad layer handler that I would ship 
with a plugin (for QGIS 3.4 and above).


The plugin creates map layouts and places a default world map layer in 
them, which we ship with the plugin.
However when users shave the project file and share it among each other, 
many find this layer to be broken.
The layer points to a data in the plugin path, which is not the same 
across machines.


The custom bad layer handler would try to see if this specific layer is 
broken and fix it for the user,
then call the regular bad layer handling "file dialog" to allow them to 
fix any eventual broken layers that are unrelated to the plugin.


I am creating my bad layer handler by subclassing QgsProjectBadLayerHandler,
thin I pass it to QgsProject by calling its setBadLayerHandler() method.
Since I want to pass it before any layer is actually loaded (so when 
launching qgis to open a project file, it would work right away)
I had to resort to a sort of ugly way of using the 
QgsProject.layerLoaded signal to make this happen.


This actually works, for the 1st time when I open a project file with 
bad layers. Then the 2nd time, QGIS always crashes.
It seems once I replaced the bad layer handler during project start, 
QGIS is not able to open a subsequent new project properly.


Here is my example in code:

class MyBadLayerHandler(QgsProjectBadLayerHandler):
""" This is a custom bad layer handler that would work as the default 
one, except it would automatically fix a specific layer that is broken. 
""" def __init__(self, path):

QgsProjectBadLayerHandler.__init__(self)
self.validLayerPath = path

def handleBadLayers(self, domNodes):
# Some logic to look for a specific DomNode to fix, oversimplified here: 
for domin domNodes:

dataSource =self.dataSource(dom)

if dataSourceis 'the broken path to the layer I want to fix':
# set correct data source then force re-read 
self.setDataSource(domNodes, self.validLayerPath)
QgsProject.instance().readLayer(dom)

# TODO: after this, call the GUI file dialog as in the default bad layer 
handler, to allow the user to fix # any other broken layers... not sure 
how to do this class MyPlugin:

"""My plugin""" def __init__(self):
self.validPath ='valid path to layer' self.badLayerHandler =None def 
hackyAndUglyReplacer(self, i, n):
""" This hacky ugly function is to replace the bad layer handler early 
on, before any layers would be loaded. it is meant to be connected to 
the `layerLoaded` signal of `QgsProject` """ # do not run further if 
there were other layers loaded before (e.g. the signal was emitted 
before) if i !=0:

return if not self.badLayerHandler:
self.badLayerHandler = MyBadLayerHandler(self.validPath)
QgsProject.instance().setBadLayerHandler(self.badLayerHandler)

def initGui(self):
# start-up code here... #connect to signal 
QgsProject.instance().layerLoaded.connect(self.hackyAndUglyReplacer)

def unload(self):
try:
QgsProject.instance().layerLoaded.disconnect()
except Exception:
pass


Does anyone know what am I doing wrong here? Have I missed something?
Why does QGIS crash every 2nd time?

I would be happy to pass the bad layer handler a better way than with 
the current signal above. But the other signals I found are emitted 'too 
late' already.

Perhaps here I am also doing something wrong?

I tried looking for help but the web barely has any trace of 
documentation on this.


I also tried to see how this is done in other plugins e.g. the 
changeDataSource plugin, but the authors  seem to have removed the code 
when they ported the plugin to QGIS 3.x

(perhaps a bad sign)

In general it seems to me this part was also overhauled in QGIS3 but 
there aren't many leads to follow on what is the current way of using 
custom bad layer handlers.


Maybe if we could put the story together on how to do this correctly, I 
could document it and put it on the web for others to refer to.


Hope you are having / had a great Sunday!

Best regards,
Aron

___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Difficulties with custom bad layer handler in plugin code

2019-07-22 Thread Áron Gergely



On 22/07/2019 01:11, Nyall Dawson wrote:

On Sun, 21 Jul 2019 at 21:16, Áron Gergely  wrote:


This actually works, for the 1st time when I open a project file with bad 
layers. Then the 2nd time, QGIS always crashes.
It seems once I replaced the bad layer handler during project start, QGIS is 
not able to open a subsequent new project properly.

Couldn't you achieve the same result by setting your bad layer handler
directly in initGui?
No, for some strange reason the bad layer handler would not get assigned 
when I tried within initGui.
I tried to find out why by looking at debug messages on qgis launch, 
reading the source code,
but it is a lot to take in with my rusty C skills so I have not found 
the answer.


But I reckoned it may be due to the plugin being loaded before a 
QgsProject singleton would be initialized.

# TODO: after this, call the GUI file dialog as in the default bad layer 
handler, to allow the user to fix
# any other broken layers... not sure how to do this

The bad news is -- unfortunately you cannot. The inbuilt bad layer
handler isn't exposed to Python in any way, and as soon as you set a
new bad layer
handler method the existing inbuilt one is completely deleted.
Understood - if that part is not exposed to the python API then I will 
not pursue the above. Thanks for letting me know!

I've been thinking about a similar situation recently, where a
client's IT department is continually replacing network paths and
moving things around (they do it roughly every 6 months, with no
notice in advance. yep.) This breaks many many paths in their qgis
projects, but the fix is actually super simple since we know what the
network path used to be and what it is now. So what I've been
pondering is whether we need a new hook to allow a "data source
pre-processor" function to be specified, much in the same way that
custom bad layer handlers would be. This would be called BEFORE
resolving any raw paths, and would simply take an input data source
string and return a processed version of it. (e.g. by replacing
outdated network paths with their new equivalent). In this way it
would be transparent to users -- the paths would be automatically
updated, and then they'd only see the bad layer handler dialog IF an
updated path still doesn't exist.

Does this sound like what you're seeking?

Nyall


Thanks for your insight Nyall!
Sounds bad with that IT Department. :(

But yes, I think that would be helpful. (I wonder who else hit a wall 
with the broken paths? )
If there would be a way to fix broken paths in python on project init, I 
would use it now to improve on our plugin.


Although my problem (or rather, our problem with Raymond) is similar but 
not exactly the same:


We created a plugin that helps to achieve consistent map layouts: the 
plugin itself ships with the correct resources (logos, symbols, and a 
world map layer)
for specific map layouting tasks and has a simple workflow via dialogs 
that creates the right layouts which the users would fill in or adapt to 
meet their needs.


The problem is that since we ship the resources with the plugin, the 
resource paths are on the plugin path which is different across machines.
So when users create map layouts, save the project file and pass it to 
another user to work on they see missing items and broken layer path, 
even though they have the plugin installed.


On the longer term we believe it would be good to have a resource 
sharing system that is native to QGIS.
That would make it very easy to share resources for plugins as well, 
without needing to instruct the users to get the resource sharing 
plugin, connect to resource repo X and pull resources a, b, c,... and so on.


I had discussions about this with Raymond and we are looking to write a 
QEP about 'native' resource sharing.


We might as well be able to live without a solution for now, as native 
resource sharing would answer our needs best.


Best regards,
Aron

Here is my example in code:

class MyBadLayerHandler(QgsProjectBadLayerHandler):
 """
 This is a custom bad layer handler that would work as the default one, 
except it would automatically fix
 a specific layer that is broken.
 """

 def __init__(self, path):
 QgsProjectBadLayerHandler.__init__(self)
 self.validLayerPath = path

 def handleBadLayers(self, domNodes):
 # Some logic to look for a specific DomNode to fix, oversimplified 
here:
 for dom in domNodes:
 dataSource = self.dataSource(dom)

 if dataSource is 'the broken path to the layer I want to fix':
 # set correct data source then force re-read
 self.setDataSource(domNodes, self.validLayerPath)
 QgsProject.instance().readLayer(dom)

 # TODO: after this, call the GUI file dialog as in the default bad 
layer handler, to allow the us

Re: [QGIS-Developer] Difficulties with custom bad layer handler in plugin code

2019-07-23 Thread Áron Gergely



Although my problem (or rather, our problem with Raymond) is similar but
not exactly the same:

Nope - it IS the same ;) You can see it in
https://github.com/qgis/QGIS/pull/30842


Yes, it's just there is more to it I think. I imagined a qgis with a 
resource sharing system where we would not have broken paths in the 
first place.
It was a comforting thought, so now the lack of it makes me see that as 
my 'real' problem.

Or maybe I am an idealist! :D


def my_processor(path):
if path.endswith('my_plugins_super_north_arrow.svg'):
   return os.path.join(os.path.dirname(__file__),
'resources/my_plugins_super_north_arrow.svg')
return path

QgsPathResolver.setPathPreprocessor(my_processor)

Now aside from my previous thought, this is of course great to have, it 
solves our problem.

Thanks for helping!

Best regards,
Aron


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

[QGIS-Developer] Pull request #30647 - review / discuss during hackfest?

2019-08-24 Thread Áron Gergely

Hello Nyall and all contributors,

I while ago I made a PR to improve on the 'world' easter egg (have 
better data under it),

as well as adding two more layers:

 - province/state boundaries
 - disputed borders

Those would not be added to the canvas when invoking the 'world' easter 
egg but could be used in the CRS selection window and as default layer 
in a project template.


Nyall was one of the people who said he would be happy to see this merged,
so he could work on a few ideas around it (mainly what I mentioned 
above: CRS selection window and project template) before the feature 
freeze on August 30th.


Here is the PR:
https://github.com/qgis/QGIS/pull/30647

I know that there are mixed opinions about shipping data with QGIS -
therefore I thought it would be handy to discuss and decide during the 
hackfest whether this PR should be merged or not as it is.


I also have my own concerns, mainly about starting to manage data, and 
their processing pipelines which I think is not a good idea, (discussion 
on the PR is starting to head in that direction now)


Id be glad for to hear your thoughts on this.

And if you are here in Bucharest too, I would be happy to sit together 
and have a chat about it;
can also sum up the story if you want to have a quick understanding 
without reading all comments / commit messages.


Thanks,

Best regards,
Aron



___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Geodesic Line Simplification

2019-10-01 Thread Áron Gergely

Hi Calvin and list,

Have you looked at the GRASS GIS v.generalize tool? 
https://grass.osgeo.org/grass64/manuals/v.generalize.html


The Douglas-Peucker algorithm is implemented there and I have used that 
with (topologic)success recently on many touching polygons. Should work 
for polylines too!


Best regards,
Aron

On 01/10/2019 08:19, Tim Sutton wrote:

Hi

On 26 Sep 2019, at 17:13, C Hamilton > wrote:


Are there any geodesic QGIS algorithms that simplify lines? 
"Simplify" just uses the projection units of measure. If there isn't 
I thought I would add this to the Shape Tools plugin. I could easily 
implement the Douglas-Peucker algorithm using geodesic math.


For GPS tracks I also see a need to throw out all points that are 
less than a certain distance or less than a certain time interval. I 
don't see any simplification algorithms that make use of time. Am I 
just missing them?


No I don’t think we have any time based simplifiers - would be a great 
addition!


Regards

Tim





Thanks,

Calvin
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org 
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


—








*Tim Sutton*

*Co-founder:*Kartoza
*Ex Project chair:*QGIS.org 

Visit http://kartoza.com  to find out about open 
source:


Desktop GIS programming services
Geospatial web development
GIS Training
Consulting Services

*Skype*: timlinux
*IRC:*timlinux on #qgis at freenode.net 

I'd love to connect. Here's my calendar link 
 to make finding time easy.



___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Problems in running OTB

2019-12-04 Thread Áron Gergely

Hi Paolo and list,

I am using the Segmentation algorithm on Linux without major problems. 
(OTB 6.6 and now 7.0 with QGIS 3.10).  But indeed it does not work out 
of the box:
Even when raster output does not not apply to the Segmentation alg , a 
"bogus" value would have to be entered in the output box to avoid an 
exception and get the alg running.


Also, the OTB processing provider settings interface has some issues:
when I try to change configuration values (namely the amount of max RAM 
), I get an error " argument has unexpected type  'int' "


Best regards,
Aron


On 04/12/2019 13:23, Pedro Venâncio wrote:

Hi Paolo,

I'm using OTB (6.6.1 and 7.0.0) with QGIS 3.10.0, without any problem, 
but I'm on Windows.


About the issues you reported (".raster.out.tif" and vectors not being 
loaded), I think this thread can explain almost all of them (I had the 
same doubts some time ago):


https://gitlab.orfeo-toolbox.org/orfeotoolbox/qgis-otb-plugin/issues/30

Best regards,
Pedro Venâncio


Paolo Cavallini mailto:cavall...@faunalia.it>> 
escreveu no dia terça, 3/12/2019 à(s) 12:00:


Moreover, the vector resulting vector layer is not automatically
loaded.
Cheers.

Il 03/12/19 12:44, Paolo Cavallini ha scritto:
> Hi all,
> OTB algs apparently do not work on QGIS 3.10 out of the box:
>
> * if a raster output is not explicitly selected I get an error:
> “.raster.out.tif” files are not supported as outputs for this
algorithm
>
> * if a vector output  is not explicitly selected (with
filename.ext) I
> get another error:
> 2019-12-03 12:30:43 (FATAL) Segmentation: itk::ERROR: No OGR driver
> known to OTB to create and handle a DataSource named
>

.
>
> If confirmed I can open two tickets.
>
> Additionally (but this must be done by OTB itself, nothing to do
with QGIS):
>
> ERROR 1: TopologyException: Input geom 1 is invalid: Ring
> Self-intersection at or near point 1651438.0098749998
4818821.1863940004
> at 1651438.0098749998 4818821.1863940004
>
> Cheers.
>

-- 
Paolo Cavallini - www.faunalia.eu <http://www.faunalia.eu>

QGIS.ORG <http://QGIS.ORG> Chair:
http://planet.qgis.org/planet/user/28/tag/qgis%20board/
___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org <mailto:QGIS-Developer@lists.osgeo.org>
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer


--
Email Signature Kind Regards,

Áron Gergely
+31 (0) 6 38 70 97 66

*Rasterra* | www.rasterra.nl <https://www.rasterra.nl>
<>___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

Re: [QGIS-Developer] Problems in running OTB

2019-12-05 Thread Áron Gergely

I added my note to the OTB gitlab issue here:
https://gitlab.orfeo-toolbox.org/orfeotoolbox/otb/issues/2001

Best regards,
Aron

On 04/12/2019 17:11, Paolo Cavallini wrote:

I can confirm it works, but not out of the box: without adding a
filename for raster and vector output I get the error described.
There is a crash due to specific geometry issue, as reported, but this
is related to specific data (available for testing if useful).
Cheers.

Il 04/12/19 17:05, Pedro Venâncio ha scritto:

Hi Paolo,

Tested here in Ubuntu Xenial, both with OTB 7.0.0 or 6.6.1, and QGIS
3.4.13 (OTB plugin), everything works, but with the issues reported by Aron.

Best regards,
Pedro


Paolo Cavallini mailto:cavall...@faunalia.it>>
escreveu no dia quarta, 4/12/2019 à(s) 15:44:

 Thanks for the feedback. Could you please add your notes to the ticket
 https://gitlab.orfeo-toolbox.org/orfeotoolbox/otb/issues/2001 ?
 Cheers.

 Il 04/12/19 14:42, Áron Gergely ha scritto:
 > Hi Paolo and list,
 >
 > I am using the Segmentation algorithm on Linux without major problems.
 > (OTB 6.6 and now 7.0 with QGIS 3.10).  But indeed it does not work out
 > of the box:
 > Even when raster output does not not apply to the Segmentation alg , a
 > "bogus" value would have to be entered in the output box to avoid an
 > exception and get the alg running.
 >
 > Also, the OTB processing provider settings interface has some issues:
 > when I try to change configuration values (namely the amount of
 max RAM
 > ), I get an error " argument has unexpected type  'int' "
 >
 > Best regards,
 > Aron
 >
 >
 > On 04/12/2019 13:23, Pedro Venâncio wrote:
 >> Hi Paolo,
 >>
 >> I'm using OTB (6.6.1 and 7.0.0) with QGIS 3.10.0, without any
 problem,
 >> but I'm on Windows.
 >>
 >> About the issues you reported (".raster.out.tif" and vectors not
 being
 >> loaded), I think this thread can explain almost all of them (I
 had the
 >> same doubts some time ago):
 >>
 >>
 https://gitlab.orfeo-toolbox.org/orfeotoolbox/qgis-otb-plugin/issues/30
 >>
 >> Best regards,
 >> Pedro Venâncio
 >>
 >>
 >> Paolo Cavallini mailto:cavall...@faunalia.it> <mailto:cavall...@faunalia.it
 <mailto:cavall...@faunalia.it>>>
 >> escreveu no dia terça, 3/12/2019 à(s) 12:00:
 >>
 >>     Moreover, the vector resulting vector layer is not automatically
 >>     loaded.
 >>     Cheers.
 >>
 >>     Il 03/12/19 12:44, Paolo Cavallini ha scritto:
 >>     > Hi all,
 >>     > OTB algs apparently do not work on QGIS 3.10 out of the box:
 >>     >
 >>     > * if a raster output is not explicitly selected I get an error:
 >>     > “.raster.out.tif” files are not supported as outputs for this
 >>     algorithm
 >>     >
 >>     > * if a vector output  is not explicitly selected (with
 >>     filename.ext) I
 >>     > get another error:
 >>     > 2019-12-03 12:30:43 (FATAL) Segmentation: itk::ERROR: No
 OGR driver
 >>     > known to OTB to create and handle a DataSource named
 >>     >
 >>
  
.
 >>     >
 >>     > If confirmed I can open two tickets.
 >>     >
 >>     > Additionally (but this must be done by OTB itself, nothing
 to do
 >>     with QGIS):
 >>     >
 >>     > ERROR 1: TopologyException: Input geom 1 is invalid: Ring
 >>     > Self-intersection at or near point 1651438.0098749998
 >>     4818821.1863940004
 >>     > at 1651438.0098749998 4818821.1863940004
 >>     >
 >>     > Cheers.
 >>     >
 >>
 >>     --
 >>     Paolo Cavallini - www.faunalia.eu <http://www.faunalia.eu>
 <http://www.faunalia.eu>
 >>     QGIS.ORG <http://QGIS.ORG> <http://QGIS.ORG> Chair:
 >>     http://planet.qgis.org/planet/user/28/tag/qgis%20board/
 >>     ___
 >>     QGIS-Developer mailing list
 >>     QGIS-Developer@lists.osgeo.org
 <mailto:QGIS-Developer@lists.osgeo.org>
 <mailto:QGIS-Developer@lists.osgeo.org
 <mailto:QGIS-Developer@lists.osgeo.org>>
     >>     List info:
 https://lists.osgeo.org/mailman/listinfo/qgis-developer
 >>     Unsubscribe:
 https://lis

Re: [QGIS-Developer] hackfest limits!!!

2020-01-21 Thread Áron Gergely

Hi all,

One more note to add to Raymond's announcement:

s-Hertogenbosch is a lovely Dutch town - but hotels can be pricey and 
the choices are somewhat limited. :(


So it is safer to arrange your hotel bookings early on.

I just did a quick sweep online - it looks fine for now ;) but you know...



Hope to see you soon!

@Tim, sad to hear. See you at another time!

Aron


On 20/01/2020 23:44, Tim Sutton wrote:

Hi

For those not sure how to register, see this page:

https://github.com/qgis/QGIS/wiki/24th-Contributor-Meeting-in-'s-Hertogenbosch

Sorry I won’t be able to join you all there :-(

Regards

Tim

On 20 Jan 2020, at 09:39, Raymond Nijssen > wrote:


Dear hackers, developers and contributors! :)

Having attended quite some hackfests in the past, I never expected to 
reach the maximum of 50 attendees for the next hackfest. But having 
already 35 subscriptions by now and knowing quite some people who are 
still considering to come, we are starting to worry a bit.


So the good news is that we will be many. The bad news is that people 
might not be welcome, or might need to work in some additional 
location (which would be lame, cause why traveling so far and not sit 
together?).


For now, please:
- subscribe if you want to be in
- add your arrival and departure datetimes to the list, so we know 
per day how many people will be present

- book hotels
- in case you unfortunately change your plans, remove yourself from 
the list to make space for somebody else


Thank you so much and hope to see you all soon!

Raymond

___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org 
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer






---

*Tim Sutton*
t...@qgis.org 





___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer
<>___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer

[QGIS-Developer] QgsJsonUtils does not parse fields - bug or a feature?

2020-07-23 Thread Áron Gergely

Hi list,

I am parsing a larger (about 200k characters) GeoJSON FeatureCollection 
string via QgsJsonUtils.stringToFields().

It contains polygon features, each with many coordinate pairs.
Despite the string being valid GeoJSON, no fields are returned.

However, if I save the string to a .geojson file and open it as vector 
layer, it opens with the attribute fields.


I am working with both QGIS 3.10.8 and 3.14.1 on Ubuntu.
Here is a simplified example of the GeoJSON structure:

{
    "features": [
    {
    "geometry": {
    "coordinates": [
    [
    [
    0.0,
    1.0
    ],
 .
                 .
 .
    [
    0.0,
    1.0
    ]
    ]
    ],
    "type": "Polygon"
    },
    "id": "abcd",
    "type": "Feature",
    "properties": {
    "attrib_a": "a text",
    "attrib_b": 1
    }
    }
    ],
"type": "FeatureCollection"
}


I found that if I do either of the below steps before calling 
QgsJsonUtils.stringToFields(), it does return the fields:


 *   significantly reduce the number of coordinate pairs
 *   Change the order of objects so that "type"  is ahead of "geometry"
   in the features.

I looked at the unit tests of QgsJsonUtils but only short geojson 
strings are tested there..


So it looks like large geometry objects in the GeoJSON feature would 
prevent reading its fields... unless "type" is parsed before them?


Is this buggy behavior? Or am I missing something?

Should I open an issue on GitHub?



Best regards,
Aron
<>___
QGIS-Developer mailing list
QGIS-Developer@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-developer
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-developer