Re: [Qgis-user] (no subject)

2023-06-22 Thread Jésahel Benoist via QGIS-User
Take a look at lidR : https://github.com/r-lidar/lidR
We've used it to count and delineate trees on a french city. Great package
with great documentation !
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] QGIS on tablets

2023-02-17 Thread Jésahel Benoist via QGIS-User
Hi,

We bought some years ago the Dell Rugged Extreme tablet and I want to say :
test before buy !

Even if QGIS works flawlessly with big projects, the Windows "tablet"
environment is just a pain, especially the virtual keyboards (plural form
as Microsoft has been unable to give something polished so we're using two)

Add to this that this real computer needs a lot of power, batteries, so is
so heavy that that you need a necklace to handle it all day.

But the worst is the "Rugged" definition. Could you imagine that there's
fans, that they are accessible behind plastic to the most common and
dangerous thing for fan on earth : dust. Look on the fourth picture to see
the fan grid.

https://www.dell.com/fr-fr/shop/ordinateurs-portables/latitude-7220-rugged-extreme/spd/latitude-12-7220-tablet/xctol7220emea

You see the point. Good luck and please share your finds.

J. Benoist

Le ven. 17 févr. 2023 à 14:50, Richard Duivenvoorde via QGIS-User <
qgis-user@lists.osgeo.org> a écrit :

> I'm (just playing) with this tablet: ThinkPad X1 Tablet Gen3
> It comes with Windows, but I run Debian Testing on it and I really like
> it, even the use of the pen.
> Not sure about ruggedized cases for it though.
>
> I'm afraid you will end up with the normal ruggedized Windows tablets
> which are available (and pretty expensive)?
>
> Regards,
>
> Richard Duivenvoorde
>
> On 2/17/23 14:43, Chiz Harward via QGIS-User wrote:
> > Hi,
> >
> > I am looking for suggestions/spec for a Windows* tablet** that can run
> QGIS during data collection and recording on archaeological sites (dusty,
> sometimes damp). The work is recording simple attributes and short text
> comments onto shapefiles of e.g. wall elevations (up to 20,000 polygons,
> although these could be split up). There will be geo-tif orthophotos of the
> wall elevations/plans as well, although these could be lo-res. All
> processing and analysis will be done in office on a desktop, tablet is just
> for recording.
> >
> > Need a tablet that can work rapidly without beachballing between
> commands or when pan across mapping. SSD, 8GB RAM enough? Any advice
> appreciated,
> >
> > *QField is not suitable for this project
> >
> > **must be a tablet that can fit in a ruggedised case, laptops are no
> good for the work
> >
> > Best wishes
> >
> >
> > Chiz
> >
> >
> > ___
> > QGIS-User mailing list
> > QGIS-User@lists.osgeo.org
> > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
> ___
> QGIS-User mailing list
> QGIS-User@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
QGIS-User mailing list
QGIS-User@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Keypress event and slowless

2022-08-04 Thread Jésahel Benoist via Qgis-user
>
> So, if you also tried with a new QGIS user profile without any external
> plugin installed, this excludes at least that the issue is due to an
> external plugin or a non standard QGIS configuration.
> Have you searched in the QGIS issue tracker at
> https://github.com/qgis/QGIS/issues for any previously reported similar
> issue?
> If no similar issue is already present, then maybe it is worth to report
> the issue there.
>
> Best regards.
>
> Andrea Giudiceandrea
>

Yes, I will do it. I usually do prefer asking there before... As there's
some other users, it's ok. For the plugin, there's also integrated plugins,
but you're certainly right.

Thank you

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Keypress event and slowless

2022-08-04 Thread Jésahel Benoist via Qgis-user
 Hi Andrea,

Yes, of course, I've tried everything. As I have to test new releases, I
test with fresh installation too. For me, a keypress event fires something
like a screen refresh/redraw, and it shouldn't (except in the main screen
area for special purposes like moving objects).

Best regards,

Jésahel

Le mer. 3 août 2022 à 16:56, Andrea Giudiceandrea via Qgis-user <
qgis-user@lists.osgeo.org> a écrit :

> *Jésahel Benoist*
> *Wed Aug 3 04:33:23 PDT 2022*
> --
>
> maybe
> to be able to know what events are triggered to try to correct this,
> because it could be a plugin or a calculated field or anything.
>
>
> Hi Jésahel,
> have you tried if the issue occurs also using a new QGIS user profile
> without any external plugin installed?
>
> Best regards.
>
> Andrea Giudiceandrea
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] Keypress event and slowless

2022-08-03 Thread Jésahel Benoist via Qgis-user
Hi,

On Windows/QGIS 3.16/QGIS 3.22 LTR, am I the only one having noticed some
annoying slowness in big projects when typing ? It happens especially in
layout when changing a legend element name or in the attribute table.

What is really annoying is that each keypress seems to trigger some heavy
calculation. I think it should only happen when exiting the field, or maybe
to be able to know what events are triggered to try to correct this,
because it could be a plugin or a calculated field or anything.

Regards,

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] DB manager PostGIS import fails for strange reason

2022-07-27 Thread Jésahel Benoist via Qgis-user
Hi Mats,

Several times I had to deal with this kind of problem and I found that the
plugin GeomAttribute can be useful to find a faulty entity in a table.
Maybe it could help you.

https://philipwhitten.github.io/geomAttribute/html/pluginTools/geomAttribute.html

Btw, I have the feeling that the code validating a new entity in QGIS is
too permissive... I have to manually correct our DB regularly as some users
are creating incorrect data (especially NULL entities) and we don't even
know how...

The plugin is also useful to correct data before import.

Regards,

Jésahel B.
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] NULL in attribute table

2022-07-06 Thread Jésahel Benoist via Qgis-user
You can also change this there :
https://docs.qgis.org/3.22/en/docs/user_manual/introduction/qgis_configuration.html#id42

Le mer. 6 juil. 2022 à 18:16, Dario C via Qgis-user <
qgis-user@lists.osgeo.org> a écrit :

> Hi there,
> I'm using an attribute table on my layout. For all the field without any
> value I have NULL. Is there any way to add an expression like (when FIELD
> is NULL Then ' ') ?
> Thank you
>
> regards,
> Dario
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Dimensioning in QGIS

2022-06-29 Thread Jésahel Benoist via Qgis-user
Hi,
Try Dimensioning plugin... Dimensioning — QGIS Python Plugins Repository

J.B.
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Automating creation of county distribution maps

2022-03-12 Thread Jésahel Benoist via Qgis-user
Great, thanks for sharing !

Le sam. 12 mars 2022 à 10:43, Bernd Vogelgesang 
a écrit :

> Hi Mike and list,
>
> I took the challenge and so far succeeded at the very moment. Mike sent me
> a (not so clean list) of species and counties.
>
> My idea was to produce an atlas. (Actually, it should be made by a report,
> but since those are a bit quirky still, I went the pure atlas way)
>
> It's a bit hacky, a more straightforward way would be nice.
>
> - cleaning the data and importing them (table species/county, county
> polygons)
>
> - create table of individual species (toolbox "Delete duplicates by
> attribute") -> 101 unique species
>
> - Setting up a relation between county layer and species/county-table on
> the county name
>
> - new text field in county layer "species" :
>
> relation_aggregate('name_of_relation', 'concatenate', "species_names",
> ',')
>
> this creates a comma-separated list of species for each county polygon
>
> Prepare Atlas
>
> Coverage layer: (fake coverage, as it does not move)
>
> - create bounding box of the county-layer (Extract layer extent)
>
> - take list of individual species and add the geometry: retrieved the wkt
> of the extent in the field calculator -> "Geometry by expression":
> geom_from_wkt('Polygon ((355937 4117435, 782844 4117435, 782844 4498773,
> 355937 4498773, 355937 4117435)')
>
> -> 101 extents with species name as atlas coverage
>
> - create new map layout
>
> - Activating atlas, setting species name-field as page name
>
> - duplication of the county-layer and setting up a rule based style:
>
> visible: array_contains( string_to_array( "species_names",','),
> @atlas_pagename)
>
> invisible: else
>
> this query will look for the pagename (= species name) in the array of
> species names in the county polygons, and if the name is in, then the
> polygon is shown in grey, alse transparent.
>
> add text field @atlas_pagename
>
> set atlas output filename to @atlas_pagename
>
> Export atlas as images
>
> DONE
>
> Question: is there a way to aggregate the species per county without
> setting up that relation beforehand? This is an extra step which would be
> nice if it could be circumvented by some cool function.
>
> Any ideas or comments?
>
> Am 12.03.22 um 10:04 schrieb Jésahel Benoist via Qgis-user:
>
> Hello Mike,
>
> I tried to follow your question and the most I read the less I understand !
> Could you simply explain what you want to see, what action the user have
> to do and what he gets?
> For this, try to give input data and what will link them : plants (table
> with plant name and states distribution?), states (geometric data with
> states names?), columns to link...
> The good point is that I'm sure QGIS can do this. But nobody will engage
> work if objective isn't precise enough.
>
> Regards,
>
> J. B.
>
>
> Le ven. 11 mars 2022 à 21:50, Mike Breiding - Morgantown WV via Qgis-user <
> qgis-user@lists.osgeo.org> a écrit :
>
>> I had the range USA range map in the screen shot and have since updated
>> it.  https://photos.app.goo.gl/ktn5quT6s6SRwrzBA
>> WV-Mike
>> 
>> On 3/10/2022 11:04 AM, chris hermansen wrote:
>> > Perhaps others are better understanding how you want to visualize the
>> > distributions, but what I get from your description is that if you have
>> > 100 (or 2500) species then you will have 100 (or 2500) maps, which
>> > sounds unwieldy to me.
>>
>> I neglected to mention the use for the distribution maps.
>> They will be used in a print brochure.
>> A page mock up can be seen here:
>> https://photos.app.goo.gl/ktn5quT6s6SRwrzBA
>>
>> The USA distribution map in the mock up was made in Qgis using the
>> information from:
>> https://plants.usda.gov/home/plantProfile?symbol=BODI2
>>
>> This is interactive and will display down to the state and county level.
>> However, they are not up to date at the state/county level. If they were
>> I would simply make a screen shot and that would be the end of it.
>>
>> The state distribution map used in the mock up was made using Qgis based
>> on data from the West Virginia University Herbarium which has the most
>> up to date information on distribution.
>>
>> WV-Mike
>>
>>
>>
>> ___
>> Qgis-user mailing list
>> Qgis-user@lists.osgeo.org
>> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
>> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>>
>
> ___
> Qgis-user mailing listqgis-u...@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Automating creation of county distribution maps

2022-03-12 Thread Jésahel Benoist via Qgis-user
Hello Mike,

I tried to follow your question and the most I read the less I understand !
Could you simply explain what you want to see, what action the user have to
do and what he gets?
For this, try to give input data and what will link them : plants (table
with plant name and states distribution?), states (geometric data with
states names?), columns to link...
The good point is that I'm sure QGIS can do this. But nobody will engage
work if objective isn't precise enough.

Regards,

J. B.


Le ven. 11 mars 2022 à 21:50, Mike Breiding - Morgantown WV via Qgis-user <
qgis-user@lists.osgeo.org> a écrit :

> I had the range USA range map in the screen shot and have since updated
> it.  https://photos.app.goo.gl/ktn5quT6s6SRwrzBA
> WV-Mike
> 
> On 3/10/2022 11:04 AM, chris hermansen wrote:
> > Perhaps others are better understanding how you want to visualize the
> > distributions, but what I get from your description is that if you have
> > 100 (or 2500) species then you will have 100 (or 2500) maps, which
> > sounds unwieldy to me.
>
> I neglected to mention the use for the distribution maps.
> They will be used in a print brochure.
> A page mock up can be seen here:
> https://photos.app.goo.gl/ktn5quT6s6SRwrzBA
>
> The USA distribution map in the mock up was made in Qgis using the
> information from:
> https://plants.usda.gov/home/plantProfile?symbol=BODI2
>
> This is interactive and will display down to the state and county level.
> However, they are not up to date at the state/county level. If they were
> I would simply make a screen shot and that would be the end of it.
>
> The state distribution map used in the mock up was made using Qgis based
> on data from the West Virginia University Herbarium which has the most
> up to date information on distribution.
>
> WV-Mike
>
>
>
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Pictures rotated 90 degrees on composer

2021-11-20 Thread Jésahel Benoist
Hi, we had this problem for a long time, in composer (!=forms). I've first
tried to add some script and special fields, but finally it's far easier
to correct all photos with XNView and its 'rotate by exif' function. See
https://newsgroup.xnview.com/viewtopic.php?t=1420#:~:text=To%20do%20this%2C%20you%20select,on%20the%20EXIF%20orientation%20flag
.
As it's a special JPEG function, it don't suffer from loss of quality and
it's faster.

Jésahel

Le ven. 19 nov. 2021 à 16:22, Nicolas Cadieux 
a écrit :

> Indeed
>
> Pictures taken with some cameras have a tag indicating if they should be
> read in landscape or portrait.  If the tag is not recognized by the
> software or the OS, it will be shown in landscape by default. It gets
> complicated when the image is shown in portrait in the Windows user
> interface but in landscape in a software.  That is when you know you have a
> problem. XNview can also do those batch operations. The other option was to
> use the image rotation in the composer.
>
> Cheers, nice to know you got it working.
>
> Nicolas Cadieux
> https://gitlab.com/njacadieux
>
> Le 19 nov. 2021 à 09:37, Dario  a écrit :
>
> Solved with a batch action in Photoshop, just saving all the picture
> (overwrite) without any modification.
>
> I think it is a problem of the picture taken by phone. You cannot see from
> width and height size the real orientation. They look portrait, but
> actually when I insert them (mostly, not all!) they are displayed rotated.
> 路‍♂️
>
> _
>
> Il giorno 19 nov 2021, alle ore 14:02, Nicolas Cadieux <
> njacadieux.git...@gmail.com> ha scritto:
>
> Hi,
> Yes, you can do an image rotation. Check out this section.
>
>
> https://docs.qgis.org/3.22/en/docs/user_manual/print_composer/composer_items/composer_image.html#id9
>
> Cheers
> Nicolas Cadieux
> https://gitlab.com/njacadieux
>
> Le 19 nov. 2021 à 02:23, Dario C  a écrit :
>
> 
> Hi,
> Sorry for bothering so much 
>
> I have a frame picture (portrait) on the report composer linked to the
> control layer parameter. It works well, each page has its own proper image,
> but they are sometimes rotated 90 degrees. I thought they were landscape
> instead of portrait, but actually window explorer shows me portrait
> orientation.
>
> Is there any way to force image orientation?
>
> Thank you
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Filter in field group sections of report

2021-10-11 Thread Jésahel Benoist
Hello Yann,

You can do it programmatically with python and a custom toolbar.

But, I had a similar problem and happily, qgis as a multipurpose tool is
widely accepted by average users and filtering can be easily explained.

In fact my problem was worst, I have tens of layers. I created two layers,
one with geometric feature, one linked to the previous with (let say)
temporal features, and finally a virtual one linking the two previous for
special purposes. All others layers are linked to the temporal one. I
created and shared the multiple layers tools toolbar that permits to filter
a set of layers based on the first in the list (which is the temporal). So
when I click on the multiple filter button, all layers are filtered, and
only the specific needed items are drawn and used for printing.

Explaining the filter button tooks me 5 minutes, really, even to the most
allergic to computers person I know. Of course readable fields names and
readable values helps a lot !

I can give you some later code for a custom toolbar with automatic
filtering that I created to speed things.

Regards

Jésahel

Le lun. 11 oct. 2021 à 14:33, Yann Voté  a écrit :

> Hi Jésahel,
>
> Thanks for your reply. Your proposed solution would be fine if it was
> just me. What I forgot to say is the purpose: I want to share the QGIS
> project with other users who have limited QGIS skills.
>
> A user story would be: the user opens the QGIS project, selects the
> polygon layer A, selects the Generate Report action from the action
> menu, clicks on the desired polygon, and the PDF report for the clicked
> polygon gets generated.
>
> Or something similar with a processing algorithm.
>
> I think I found a workaround by using an atlas instead of a report. An
> atlas is OK for this particular case: main polygon layer A related with
> a non-geometric layer B whose data can be displayed within an Attribute
> Table item. Contrary to a report, an atlas output can be filtered with
> the `is_selected()` expression.
>
> I will continue to explore this path and let everyone know the found
> solution in the forum thread when I'm done.
>
> But I still believe that, for more complex use cases, namely maps in
> sections and related maps in subsections, which require a report, a
> filter option would be extremely useful.
>
> Regards.
>
> Yann
>
>
> Le 10/10/2021 à 23:20, Jésahel Benoist a écrit :
> > Hi Yann,
> >
> > As I'm often using reports based on filtered datas, and as I see that
> > you know how to filter, I don't really understand what is the problem.
> > You can just apply a filter in the main ui on the a or b layer, or make
> > virtual layers with only the needed datas. Then use the report (close
> > when a change is made in the main ui).
> >
> > Regards,
> >
> > Jésahel
> >
> > Le dim. 10 oct. 2021 à 18:53, Yann Voté  > <mailto:ygver...@lilo.org>> a écrit :
> >
> > Hi everyone,
> >
> > Let's imagine we have a polygon layer named Layer A with tons of
> > features (tens of thousands), and an attribute layer named Layer B
> with
> > even more features. Each polygon in Layer A is associated with one or
> > more rows in Layer B.
> >
> > Now suppose we have created a report with a top section for Layer A
> > containing a map centered at each polygon, and a subsection for
> Layer B
> > showing attributes for each related B row.
> >
> > Is there a way to output the report for exactly one polygon in layer
> A,
> > or for only some polygons (for example selected polygons) ?
> >
> > And is there a way in the subsection to output only some of the
> related
> > rows based on some filter expression ?
> >
> > I am aware of this feature request
> >
> > https://github.com/qgis/QGIS/issues/44821
> > <https://github.com/qgis/QGIS/issues/44821>
> >
> > but is there a way to achieve this with more steps in the UI or with
> > pyQGIS ?
> >
> > Thanks a lot !
> >
> > Regards.
> >
> > --
> > Yann Voté - ygver...@lilo.org <mailto:ygver...@lilo.org>
> > ___
> > Qgis-user mailing list
> > Qgis-user@lists.osgeo.org <mailto:Qgis-user@lists.osgeo.org>
> > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> > <https://lists.osgeo.org/mailman/listinfo/qgis-user>
> > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> > <https://lists.osgeo.org/mailman/listinfo/qgis-user>
> >
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Filter in field group sections of report

2021-10-10 Thread Jésahel Benoist
Hi Yann,

As I'm often using reports based on filtered datas, and as I see that you
know how to filter, I don't really understand what is the problem. You can
just apply a filter in the main ui on the a or b layer, or make virtual
layers with only the needed datas. Then use the report (close when a change
is made in the main ui).

Regards,

Jésahel

Le dim. 10 oct. 2021 à 18:53, Yann Voté  a écrit :

> Hi everyone,
>
> Let's imagine we have a polygon layer named Layer A with tons of
> features (tens of thousands), and an attribute layer named Layer B with
> even more features. Each polygon in Layer A is associated with one or
> more rows in Layer B.
>
> Now suppose we have created a report with a top section for Layer A
> containing a map centered at each polygon, and a subsection for Layer B
> showing attributes for each related B row.
>
> Is there a way to output the report for exactly one polygon in layer A,
> or for only some polygons (for example selected polygons) ?
>
> And is there a way in the subsection to output only some of the related
> rows based on some filter expression ?
>
> I am aware of this feature request
>
> https://github.com/qgis/QGIS/issues/44821
>
> but is there a way to achieve this with more steps in the UI or with
> pyQGIS ?
>
> Thanks a lot !
>
> Regards.
>
> --
> Yann Voté - ygver...@lilo.org
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] [QGIS 3.16] Discovered some glitches with styles and attributes table lengthy fields

2021-10-08 Thread Jésahel Benoist
I tried on a geopackage and found two things :
- Geopackage also has a field length limit in the attributes table. Maybe
it's well known...?
- The style load and save problem doesn't occur on geopackage but only on
our MSSQL database so far.

The style bug happens in the layer properties panel, in load style from the
database. Restore default style works. From my python code, I think that
the getStyleFromDatabase() has some bug with MSSQL db.

Le jeu. 7 oct. 2021 à 17:37, Jésahel Benoist  a écrit :

> Hello list,
>
> I had some strange behaviour when trying to load a layer's default style
> from my DB in the properties panel, I got the error "Root  element
> could not be found".
>
> I opened the layers_styles table directly with the attributes table and
> discovered that the record's  styleQML got truncated.
>
> The normal length of this field is 69Kb. Truncated is 32Kb. Impossible to
> add characters in the table. And modifying style always give a truncated
> size around 32Kb.
>
> Strangely, using the style panel to load and save by default works !
>
> By exporting the layer_styles table in a kml file, I see that everything
> is correctly stored in the DB.
>
> Btw, the python code I was using to load default style from db is also
> broken...
>
> So I think there's some bug in one of the default style loading internal
> functions and that the attributes table maximum editable field length is
> around 32Kb.
>
>  Am I missing something?
>
> Regards,
>
> Jésahel
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] [QGIS 3.16] Discovered some glitches with styles and attributes table lengthy fields

2021-10-07 Thread Jésahel Benoist
Hello list,

I had some strange behaviour when trying to load a layer's default style
from my DB in the properties panel, I got the error "Root  element
could not be found".

I opened the layers_styles table directly with the attributes table and
discovered that the record's  styleQML got truncated.

The normal length of this field is 69Kb. Truncated is 32Kb. Impossible to
add characters in the table. And modifying style always give a truncated
size around 32Kb.

Strangely, using the style panel to load and save by default works !

By exporting the layer_styles table in a kml file, I see that everything is
correctly stored in the DB.

Btw, the python code I was using to load default style from db is also
broken...

So I think there's some bug in one of the default style loading internal
functions and that the attributes table maximum editable field length is
around 32Kb.

 Am I missing something?

Regards,

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] batch operation on gpkg with multiple layers

2021-09-24 Thread Jésahel Benoist
Hi Nicolas,

I had similar questions and so I looked and found that it's easy to mix
normal qgis (like loading all layers, using intensively the great browser
panels to drag'n'drop), some tools (like the packaging tool) and some basic
python with this simple loop :
   selectedLayers = iface.layerTreeView().selectedLayersRecursive()
for layer in selectedLayers:
layer.startEditing()
;Do your stuff here
layer.triggerRepaint()

I've created a basic plugin (https://github.com/djes/MultipleLayersTools)
for my own needs, take a look at the code. If I have time I could add some
of your needs.
Btw, using geopackage is great for exchange and backup. But a real db
server is a must have.

Regards,

Jésahel

Le jeu. 23 sept. 2021 à 22:33, Nicolas Cadieux 
a écrit :

> Hi,
>
> Before I go to my default mode and python my way through this, is there a
> plugin that would permit me to perform batch operation on all the layers
> found in a single .gpkg file?  My geopackages contain hundreds of layers
> (from autocad) (contain identical data structures) and I would like to do
> things like:
>
>- Perform field calculator operations on each layer within the
>geopackage
>- Split all geopackage layer with a field
>- Merge multiple layers in a new geopackage
>
> I guess FME would be another way out? I there an OpenSource equivilant to
> this? (I have a home version but I need to respect the license for this
> one.)
> Nicolas
>
> --
> Nicolas Cadieuxhttps://gitlab.com/njacadieux
>
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Themes, visibility, layout, report, atlas and Layer ID vs Layer name

2021-08-20 Thread Jésahel Benoist
Le ven. 20 août 2021 à 15:37, Alexandre Neto  a
écrit :

> I still don't understand what you mean by updating a group...
>

An example : a layer group is a way for us to group layers by their use. We
have some groups with 20-30 layers with sub-groups. Sometimes for an update
we add/remove a layer from the group, change its symbology, add/remove some
fields. To update projects, or to add or remove functionalities, we often
use layer definition files. But by using this, new layers ids are changed
and so the templates need to be revamped. We have defined projects, and
some users have more than 50 templates...


> Anyway, maybe others have faced similar problems, I would try the qgis-dev
> mailing list
>

Thank you !
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Themes, visibility, layout, report, atlas and Layer ID vs Layer name

2021-08-20 Thread Jésahel Benoist
Hi Alexandre,

Le jeu. 19 août 2021 à 23:51, Alexandre Neto  a
écrit :

> Hi,
>
> Actually, in the past, most things depended solely on layer names. As
> Charles mentioned this posed lots of problems when there were layers with
> the same name.
>

Yes, it can't be solely on layer names. An id is necessary. But I think a
random and changing id is a problem too, especially if the user can't
define it.


> Maybe I did not understood the difficulty that you are facing, but if you
> need to swap layers, instead of loading a new layer and remove the old one,
> you can simply use the change data source functionality to change the
> source of UL our data, this will keep your layer id intact. Besides, even
> if the layer attributes are different, as long as the ones used by atlas,
> styles, etc are kept, every should keep working fine.
>

It is fine especially for users using files like shapefiles. But the point
is not about data sources, it is more about updating layers when needed in
well defined projects and having their id reinitialised. The source is the
same.

For example when I'm updating a group of layers about a specific topic,
users can only update this specific group in their projects. But if they
do, they'll have to change their templates too. A group may contain
modified and new layers, what would need a lot of work to simply update.


> Besides the change data source option on each layer context menu, you can
> also use the change data source plugin for when you want to change too many
> layers.
>

Yes, I'm using these a lot. It's great, especially when I'm doing portable
versions of my projects.


> Best regards,
>

Best regards too

Jésahel



>>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Themes, visibility, layout, report, atlas and Layer ID vs Layer name

2021-08-19 Thread Jésahel Benoist
Le jeu. 19 août 2021 à 21:34, Charles Dixon-Paver  a
écrit :

> Maybe a better discussion to be having is "can we make it possible to
> manually edit layer ids", but i think that will probably be dependant on
> the existing QEPs like
> https://github.com/qgis/QGIS-Enhancement-Proposals/issues/76
>
>>
Thank you for this reference. I'm not so surprised that the team has
already worked on this change. There's something to do, maybe without going
so far...




___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Themes, visibility, layout, report, atlas and Layer ID vs Layer name

2021-08-19 Thread Jésahel Benoist
Le jeu. 19 août 2021 à 21:25, Sebastian Gutwein  a écrit :

> Jesahel,
> This may be something you already do and I don't know if this would save
> you any time but I often set up project variables in situations where I am
> using a layer across many expressions or layouts.
> Project>Properties>Variables
> For example when I am referencing a DEM in expression over and over I
> create a variable DEM and set to to the layer ID e.g.
> 'DEM_d44338fa_1bf5_4ea6_b58e_7489ea8b28a8' and then in my expression
> reference @DEM in my expressions. While it is still a little annoying to
> have to change the variable when I change the DEM I only have to change it
> in one place.
> -Bas
>
>
Thank you Sebastian, it's a good solution for some purposes like
expressions. I'll try to use it more.



>>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Themes, visibility, layout, report, atlas and Layer ID vs Layer name

2021-08-19 Thread Jésahel Benoist
Le jeu. 19 août 2021 à 20:23, Charles Dixon-Paver  a
écrit :

> I would imagine there are just far too many projects and use cases where
> the same layer name is used for multiple layers.
>

Yes, certainly. But the random id is a bad solution. I think the id should
be created sequentially and could be modified by the user.

Saving and loading themes etc is a feature request I imagine.
>

Yes :)

Copying styles between layers is supported (and you can save style and
> layer definitions).
>

Yes, a good tip is to assignate keys to copy/paste style.

I imagine most issues can be resolved by just using an expression based id
> wherever possible, with something like this:
>
> QgsProject.instance().mapLayersByName('World Map')[0].id()
>
>>
Sure


>>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] Themes, visibility, layout, report, atlas and Layer ID vs Layer name

2021-08-19 Thread Jésahel Benoist
Hello all,

QGIS is now my favorite everyday tool. Anyway, there's something that is a
real pain in the ass, the choice to use layer ID instead of layer name in
layouts/reports/atlas/themes.

First, let me explain that I have a lot of layers so I'm using groups, I
import/export needed groups with layers definition files and I'm often
using the name to track the versions between projects.

At this stage, one bad thing is that deleting a layer and reloading is
changing its ID and so... All layouts/reports/atlas need to be corrected.
So I'm not deleting anymore groups/layers but instead have more dedicated
projects, and I have created some scripts and plugins to alter existing
layers, and loads/saves styles in DB. Fine but not easy for everybody and
needs to correct more projects when needed.

Today I discovered that themes are also based on layers ID... But there
isn't any way to load/save themes configuration. How to know what was the
theme configuration before a change ? Only by peeking around in the project
file or some python. But even with a save/load feature, when a modification
occurs, all projects need to be corrected.

Well, as you can see, for some years that I've been working with QGIS,
its use of the layer ID instead of layer name is clearly the most annoying
thing in this great software. I think that is also a reason for some
features not to be created.

I imagine that this is low level and needs a lot of modifications so I'm
not asking for a change now. But could a discussion about this be initiated
?

Best regards to all,

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


[Qgis-user] QGIS on a Windows tablet

2021-05-27 Thread Jésahel Benoist
Hi,

We bought a strong tactile tablet for our everyday underground survey,
based on Windows. Despite the Windows glitches especially with the virtual
keyboard(s) and the tablet mode, it works well. The time spent at office is
noticeably reduced. I've done a toolbar facilitating creation,
export/import and all the great QGIS tools/extensions are there if needed.

There's also some little problems with QGIS :
1. The panel scrolling (for example in layers panel to go up and down)
doesn't work with the "two fingers" normal behaviour on tablet. It acts
like a one click/deposit with the first selected element. We have to click
precisely on arrows or slider, not always easy.
2. The magnet is not usable for entity creation. As the user doesn't move
the pointer but only click once near the interest point, there's no magnet,
the entity is created at the wrong place.
3. The map move/zoom needs to select the hand tool, when with a mouse the
third button is so convenient.

Nothing that makes impossible the work  anyway. The experience is not over
and we'd be happy to share with other users.

Thanks again to the QGIS team for this great software !

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Multiple Layer Selection

2021-04-24 Thread Jésahel Benoist
I also think that tools should be updated to work on multiple layers. For
now, you can apply some changes (crs for example) to several layers by
using the main menu. Another trick is to assign a key to "copy style" and
another to "paste style". I've also done a plugin to change edit mode and
filters.

Regards,

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] First steps with 3D Scan Data?

2021-03-26 Thread Jésahel Benoist
You should make a try with the 3d live scanner Android app by Lubos
Vonasek. It offers live photogrammetry with a simple smartphone (better
with a tof sensor).

I'm looking too for easy solutions to use scans with QGIS.

Regards

Jésahel

Le ven. 26 mars 2021 à 09:02, Bernd Vogelgesang 
a écrit :

> Hi Benoit,
>
> as I was not present when the scans were made, I can only assume that
> this was a laser scanner on a tripod.
>
> With the sent data, there is a Trimble Scan Explorer Viewer software
> where I can make a "virtual walk" through the scene, so there have to be
> photos but also laser scan data as I can see from different view modes.
>
> As I said, this is the very first time I get in touch with this stuff,
> and Google was of no big help so far.
>
> Besides of tons of other files, the bigger ones with around 50 to 80 MB
> are .rwcx and .tzf files.
> I hoped that someone would know what these file explicitly hold, and
> what I have to do to get them e.g. into QGIS or other open source software.
>
> Cheers,
>
> Bernd
>
> On 26.03.21 08:40, info wrote:
> > Hi Bernd,
> >
> > Well, could you give more info? E.g. what kind of scan:
> > laser/lidar/photo/other? This will influence your workflow.
> >
> > +/-Open source laser/lidar could be based on lastools [1]
> > Open source photogrammetry could be based on AliceVision meshroom
> > [2,3],  MeshLab [4] and blender [5]
> >
> > In photogrammetry: Agisoft metashape [6] and pix4D [7] as good
> > commercial products.
> >
> > BTW: 32 scans, if photos, is quite a very low number of photos for
> > reconstructing a 3D scene!
> >
> > Hope this helps.
> > Cheers,
> > Benoit de Cabissole
> >
> > [1] http://lastools.org/
> > [2] https://alicevision.org/#photogrammetry
> > [3] https://github.com/alicevision/meshroom
> > [4] https://www.meshlab.net/
> > [5] https://www.blender.org/
> > [6] https://www.agisoft.com/
> > [7] https://www.pix4d.com/
> >
> >
> >
> > On 25/03/2021 23:07, Bernd Vogelgesang wrote:
> >> Hi folks,
> >>
> >> in a project on a former dumpside now to be transformed into a sand
> >> lizard habitat, I saw the chance to get my hands dirty for the first
> >> time on 3D scan data (terrestrial). I received 10GB of stuff, and now
> >> I'm completely lost.
> >>
> >> The data consists of .rwcx files, .tzf files and lots of other stuff.
> >>
> >> Is there any chance that I can process any of this data with an open
> >> source stack?
> >> Or what should be done, to make them digestible?
> >>
> >> Second step: There seem to be 32 different scans of the area form all
> >> angles. In case I succeed to somehow load the data, how do I combine
> >> them ?
> >>
> >> For the first steps, I actually "only" would like to generate a decent
> >> DEM from the data to be able to place some features on a map for the
> >> guys in charge to do the habitat stuff.
> >>
> >> Any kind of hints or links to reads about this topic would be
> >> appreciated
> >>
> >> Cheers,
> >>
> >> Bernd
> >>
> >>
> >> ___
> >> Qgis-user mailing list
> >> Qgis-user@lists.osgeo.org
> >> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> >> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Toggle Attribute

2020-11-22 Thread Jésahel Benoist
Can't you just use layer's actions?

djes

Le dim. 22 nov. 2020 à 08:43, Bernd Vogelgesang 
a écrit :

> I had a similiar use case, see here:
> https://gis.stackexchange.com/q/322544/8202
>
> Unfortunately, I just noticed the answer on my post then right now, so I
> did not dig any deeper.
>
> Basic thing is, that you can establish a "connection" between two layers
> by an "aggregate" function.
>
> But how to use that to change the style on e.g. a hover, is still beyond
> my capabilities, but I'm prettey sure there  is some clever way to
> accomplish that. Sadly, I'm not that clever. Maybe something with rule
> based style?
>
> Cheers,
>
> Bernd
>
> On 21.11.20 11:51, L.W. wrote:
> > Hi,
> >
> > is there a way to have a feature on map and when I press/click/hover on
> > it that some event is raised?
> >
> > Primary I want to toggle an attribute field true/false.
> >
> > I than will e.g. display a special symbol(layer) to an other feature.
> >
> > Example: Feature A has a foreign key to Feaure B, when B is hovered then
> > A's symbol should be yellow instead of green.
> >
> > Regards
> >
> > ___
> > Qgis-user mailing list
> > Qgis-user@lists.osgeo.org
> > List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> > Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user


Re: [Qgis-user] Show multiple photos attached to one feature

2020-10-17 Thread Jésahel Benoist
Hi,

Did you simply try a drag'n'drop custom form ? It's not a well documented
feature but it's really easy to use. In the layer properties, go to
[image: image.png]
And for all the pictures fields, choose attachment as widget type and the
following options (click on the left panel to choose the field, the middle
panel is to arrange the fields)
[image: image.png]
Now, your form is able to display correctly any numbers of well
dimensioned pictures. Use the middle panel to group them, create tabs or
containers (a bit tedious, but it works !)

Regard,

djes

Le sam. 17 oct. 2020 à 13:33, Bernd Vogelgesang 
a écrit :

> Hi Brent,
>
> thanx for sharing your solution.
>
> I think, there is quite some need for some core functionality in QGIS for
> handling photos, as this quite a common need for a lot of people.
>
> Just this week, there was this conversation about the removal of the eVIS
> plugin in QGIS3.
> Those hacks of you are nice, but far beyond the abilities of normal users
> (apart form the fact the this information will never be found by anyone
> anymore, buried in this mailing list)
>
> Would be so nice to have a flexible in-QGIS-solution for geotagged image
> viewing along with its associated data without cumbersom hacks.
> Having a working standard tool, one could adjust the workflows to just
> this tool, and lots of people would be happy (including me, dealing with a
> lot of photos too)
> I hope one day there will be a crowdfunding for such a tool, as it seems
> this area is quite out of scope of the core developers.
>
> Cheers,
>
> Bernd
>
> On 17.10.20 06:55, Brent Wood wrote:
>
> Hi Sophia,
>
> I suggest you set up a QGIS Action on the layer to view the images for a 
> feature.
>
> For a single feature, your data needs to contain a field with all the image 
> names space separated (so no whitespace within names unless you want to make 
> life difficult!!).
>
> The action will be a batch file (Windows - painful, or Powershell) or script 
> (Linux/Mac - easy) concatenate the path to each filename, then open each file 
> with an image viewer.
>
> eg:
> a point feature has this text as a field (called filename):
> P1010005.JPG P1020700.JPG
> (the names of two pictures associated with the point feature)
>
> I write a simple shell script (I'm on Linux) to iterate through a list of 
> files (I called it open_images):
> #! /bin/bash
> #
> # iteratively opens images passed on the command line
> #
> FILES=$@
>
> for FILE in $FILES ; do
> eom /home/baw/Pictures/$FILE
> done
>
> The bash script sets the "$FILES" variable to store the list passed on the 
> command line ($@)
> It then uses the eom program (simple Linux image viewing program) to 
> iteratively open each file in the list,
>   prepending the path to the file for each one.
>
> In QGIS, I create an Action on this layer called "open image", it contains 
> the command:
> /home/baw/qgis/open_images [%filename%]
> This is the path to my my script, followed by the list of image names.
>
> So, if I then select the action tool in QGIS, when I click on a feature on 
> the canvas, QGIS runs the command as set up in the action, which is my 
> script. It passes the contents of the "filename" field for the feature as a 
> command line parameter. (essentially runs the command: 
> /home/baw/qgis/open_images P1010005.JPG P1020700.JPG
>
> The script then shows the first file, then the second, etc. whenever you 
> click on a feature in QGIS. You can have a list with as many images per 
> feature as you like (within reason... 3 might be a problem!!
>
>
> Hope this helps, I find the Action tool very useful for this sort of thing. 
> Not quite as easy in Windows, which is not primarily a command line setup, 
> but can still be done.
>
>
> Cheers
>
> Brent Wood
>
> Principal Technician, Fisheries
> NIWA
> DDI:  +64 (4) 3860529
>
> 
> From: Qgis-user  
>  on behalf of chris hermansen 
>  
> Sent: Saturday, October 17, 2020 16:20
> To: sophia couchman  
> Cc: qgis-user  
> Subject: Re: [Qgis-user] Show multiple photos attached to one feature
>
> Sophia and list,
>
> On Fri, Oct 16, 2020, 06:20 sophia couchman 
> mailto:choccycouch...@iname.com> 
> > wrote:
> Hi All,
>
> I have mapped individual trees in a wood using QGIS and QField in a Layer 
> called Trees.  Each Tree/Feature contains a number of fields.  I included a 
> field for taking photographs and for each tree I took a number of 
> photographs, anywhere from 2 to 6.
>
> I then brought the QField data onto the computer.  When I right click on an 
> individual feature using the Identify Features arrow the Identify Results box 
> appears.  It contains all the fields including the photo field but this 
> contains only one photograph in this format- DCIM/trees_20201010165100197.jpg 
> but not the rest.  How can I have the rest of the photographs listed here too?
>
> I think that if you have up to six photos you are going to need up to six 
> fields to put them in, are you 

Re: [Qgis-user] Do you have any QGIS plugin feature requests?

2020-07-14 Thread Jésahel Benoist
Hi,

Thank you for your efforts ! What I would need is a dynamic transformation
tool with handles, and a panel allowing to define precisely the center,
like in drawing software. See https://images.app.goo.gl/2aNd4bbka7X943gG7

Regards,

Jésahel

Le lun. 13 juil. 2020 à 21:40, C Hamilton  a écrit :

> Hi Everyone,
>
> I find that I have extra time on my hands so I would like to know if
> anyone has any feature requests for any of my plugins.
>
> Lat Lon Tools
> https://plugins.qgis.org/plugins/latlontools/
>
> Shape Tools
> https://plugins.qgis.org/plugins/shapetools/
>
> KML Tools
> https://plugins.qgis.org/plugins/kmltools/
>
> Lock Zoom to Tile Scale
> https://plugins.qgis.org/plugins/lockzoom/
>
> My criteria for picking up a new effort would be that it benefits a large
> number of QGIS users, is somewhat related to my existing plugins, minimal
> to moderate development, and sounds like a fun project. I would also
> consider something not related to one of the plugins if I think it would be
> worthwhile and looks like it would be fun to work on.
>
> Do you have any suggestions or requests?
>
> Thanks,
>
> Calvin
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

[Qgis-user] null geometries workaround

2020-07-02 Thread Jésahel Benoist
I had to deal with null geometries (points) in a geopackage. As it shows
some QGIS strange behavior I decided to post this.

When the attributes table is by default on "filtered by view", switching to
"show all" is filtering null geometries. No way to show them... By changing
the default behaviour in the options to "show all", there's no more filter,
but it isn't possible to find faulty lines ; all graphic tools are working
as if everything was correct.

I've found that the "geometry attribute table" plugin by P. Whitten can
help, however, I wondered if there was a standard tool to do the job.

With QGIS 3.10.7, the 'removenullgeometries', 'fixgeometries',
'checkgeometries' processing tools doesn't work.
The checkgeometry tool finds them, but gives only the id without any option
to fix.

I found with "DB browser with SQLite" that the geometry was there, but x
and y were 0x   f87f. This is for 'not a number' (nan) value.
But I didn't find any expression to check for this value...

Finally, I found two ways to find the faulty lines :
The first is to create a calculated field with $x as value. (nan) is
clearly shown then.
The second is to make a filter with this simple formulae : if
(to_int($x)=0, true, false). The to_int() converts the nan value to 0, et
voila. Easy.

You're then free to add a part or delete the faulty lines.

Hope it helps some people...

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] wishing for accurate lattitude/longitude from a cell phone

2020-05-24 Thread Jésahel Benoist
For years we did surveys with a customized solution with a Starfire GPS (
https://en.m.wikipedia.org/wiki/StarFire_(navigation_system)). It needs a
subscription for best accuracy (see
https://www.navcomtech.com/en/product/globalcorrectionservice/). It was
linked to a trimble handheld data collector like this
https://geospatial.trimble.com/products-and-solutions/geo-7x that have
another integrated GPS. Pathfinder office is a great piece of software.
I have to say that it was a bit difficult to handle all of this and needs a
lot of checking and correction to have something reliable.

I think it should be possible to use a smartphone. I did some tests with Mobile
topographer which is pretty good and can be connected to an external gps
using Bluetooth/serial/usb converters and some Android dedicated apps (like
Bluetooth gps provider). But results needs to be checked, and it takes time.

The accuracy is not all. A GPS has to be fast ! Professional GPS really are
faster.

I have to say that if I had to make large surveys again, I'd prefer to rent
a professional solution. Maybe it's not cheaper but quality and saved time
is worth the price.

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Map contest: mapping Pi for the 3.14 splash screen

2020-05-15 Thread Jésahel Benoist
I do prefer Tau ( https://tauday.com/tau-manifesto ) ;)

Maybe in a few versions :)

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Features geometry/attributes inconsistency ?

2020-05-14 Thread Jésahel Benoist
As it could be useful to some people, here's a little script to copy /
paste selected features from a layer to another.

For a lot of layers, I use at first the MultipleLayerSelection (here's the
3.0 beta : https://github.com/felferrari/MultipleLayerSelection) that
permits to select features from all layers with a rectangle.

Adapts and run this script :
---
def selectedFeaturesCopy(sourceLayerName, destLayerName):

sourceLYR = QgsProject.instance().mapLayersByName(sourceLayerName)[0]
destLYR = QgsProject.instance().mapLayersByName(destLayerName)[0]
destLYR.startEditing()
# uncomment (remove the #) the following line to delete features in the
destination layer first
#destLYR.deleteSelectedFeatures()
iface.copySelectionToClipboard(sourceLYR)
iface.pasteFromClipboard(destLYR)
# uncomment the following line to commit your changes automatically.
Personally I prefer to verify first ;)
#destLYR.commitChanges()

# Create and adapt as much as lines as you have layers to copy
selectedFeaturesCopy('source layer 1', 'destination layer 1')
selectedFeaturesCopy('source layer 2', 'destination layer 2')
---
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

[Qgis-user] Features geometry/attributes inconsistency ?

2020-05-13 Thread Jésahel Benoist
Hi,

I'm working with a lot of layers and need to copy/paste features with
attributes from source layers to destination layers, within a rectangle.

I'm using the "multiple selection by rectangle" plugin by Felipe Ferrari
and Luiz Andrade to make a selection on all my layers and looked for a
script but do not find something simple and easy.

So I've rapidly coded this :
---
def selectedFeaturesCopy(sourceLayerName, destLayerName):

sourceLYR = QgsProject.instance().mapLayersByName(sourceLayerName)[0]
destLYR = QgsProject.instance().mapLayersByName(destLayerName)[0]
destLYR.startEditing()
data_provider = destLYR.dataProvider()
data_provider.addFeatures(sourceLYR.getSelectedFeatures())
destLYR.commitChanges()

selectedFeaturesCopy('source layer', 'destination layer')
---
Badly, I see that, as I rode elsewhere, it only copies geometry, not
attributes. I'll have to parse every feature to add the attributes.

So far I understand that features are only geometries. Why is it called
features then ?

More than that, when I look at the QGIS code, I see that some functions
dedicated to features do work with attributes too ?! Isn't it inconsistent ?

Wouldn't it be more efficient that some methods, like addFeature(), have at
least a flag to add attributes too ? In the addFeature() code (
https://qgis.org/api/qgsvectorlayer_8cpp_source.html#l00993), the flag
seems unused.

Regards,

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Multi users environment: From geopackage to a database?

2020-05-06 Thread Jésahel Benoist
I forgot to cite this important discussion :
https://github.com/qgis/QGIS/issues/27899
that could help in some situations with the following environment variables
:

OGR_SQLITE_JOURNAL=DELETE
SQLITE_USE_OGR_VFS=YES



Le mer. 6 mai 2020 à 12:47, Jésahel Benoist  a écrit :

>
> Le mer. 6 mai 2020 à 12:00, Stefan Keller  a écrit :
>
>> Jésahel  wrote
>> > I've created a script to deactivate wal on samba shares, because samba
>> is the main issue.
>> > It contains this only line :
>> QSettings().setValue("/qgis/walForSqlite3", False)
>>
>> That's interesting. Are you sure it's Samba?
>> SQLite FAQ [2] confirms that NFS has problems.
>> Did not find issues on Samba, but file locking with fcntl is mentioned
>> here [3].
>
>
> No, I was speaking specifically of my concern on samba shares, based on a
> lot (a lot !) of reading/testing like
> https://trac.osgeo.org/gdal/wiki/UserDocs/SQLite
> https://www.sqlite.org/wal.html
>
> https://gis.stackexchange.com/questions/224188/geopackage-error-is-mounted-and-in-wal-mode-this-combination-is-not-allowed
>
>
> I confirm multi-users reading is possible.
>
> If you have problems with WAL files (corrupted or unusable gpkg), you can
> open the gpkg file with spatialite or another program and enter these SQL
> queries :
> PRAGMA integrity_check;
> PRAGMA journal_mode = DELETE;
>
>
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Multi users environment: From geopackage to a database?

2020-05-06 Thread Jésahel Benoist
Le mer. 6 mai 2020 à 12:00, Stefan Keller  a écrit :

> Jésahel  wrote
> > I've created a script to deactivate wal on samba shares, because samba
> is the main issue.
> > It contains this only line : QSettings().setValue("/qgis/walForSqlite3",
> False)
>
> That's interesting. Are you sure it's Samba?
> SQLite FAQ [2] confirms that NFS has problems.
> Did not find issues on Samba, but file locking with fcntl is mentioned
> here [3].


No, I was speaking specifically of my concern on samba shares, based on a
lot (a lot !) of reading/testing like
https://trac.osgeo.org/gdal/wiki/UserDocs/SQLite
https://www.sqlite.org/wal.html
https://gis.stackexchange.com/questions/224188/geopackage-error-is-mounted-and-in-wal-mode-this-combination-is-not-allowed


I confirm multi-users reading is possible.

If you have problems with WAL files (corrupted or unusable gpkg), you can
open the gpkg file with spatialite or another program and enter these SQL
queries :
PRAGMA integrity_check;
PRAGMA journal_mode = DELETE;
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Multi users environment: From geopackage to a database?

2020-05-06 Thread Jésahel Benoist
Hi Bruno,

I've worked a lot on this issue for two years now. I've started with sqlite
(that was faster and better) but finally I decided to migrate to
geopackage. It was painful at first but now it's OK. But it needs some
rules.

First, I've broken the original big geopackage files into smaller ones. The
users are advised to work only one by one on a specific thematic/file (read
access is possible).
I've created a script to deactivate wal on samba shares, because samba is
the main issue. It contains this only line :
QSettings().setValue("/qgis/walForSqlite3", False)
You should download some tools like Spatialite_GUI
and SQLiteDatabaseBrowser so that you can really work on the db and have
better control. QGIS's dbmanager is a bit limited and sometimes buggy for
sqlite/geopackage, especially with special chars.
Try to work with QGIS internal explorer, it's a tool that has good
export/import functions.
Backup files at least one time a day !

Now with the covid I have created my own online postgis server so that we
can work at home without "help" of IT department and it's GREAT.
Multi-user, faster, smaller, stronger (lol). And some nice capabilities
like spatial filtering ! I highly recommend this.

Questions for all : I've recently discovered this
https://gdal.org/user/virtual_file_systems.html#virtual-file-systems
Wouldn't it be possible to avoid samba's multi-users bug with vsi ?

Jésahel



Le mer. 6 mai 2020 à 09:12, Andreas Neumann  a écrit :

> Hi Bruno,
>
> Unfortunately it is a known issue that Geopackages and QGIS are bad at
> handling simultaneous write and even read requests and developers are
> working on finding solutions (hopefully soon). In single user scenarios
> Geopackages are fine. But Multiuser must be avoided, even for reading only,
> unfortunately.
>
> As to PostgreSQL vs. Postgis: Postgis is the spatial extension of
> PostgreSQL. If you need geometries (which I assume) than you will need
> Postgis.
>
> Andreas
> Am 06.05.20 um 08:58 schrieb bru...@mailbox.org:
>
> Hi
>
> In my company we are five people who sometimes work with GIS, and we are
> moving from ArcGIS to QGIS (how cool is QGIS and SLYR!) and in this context
> from ESRI file geodatabase to geopackage. Today we run into serious issues
> when two people worked with the same geopackage. I was aware, that it is
> dangerous and unwise to edit the same geopackage from two different
> computers at the same time. But I did not expect both QGIS applications to
> crash immediately and the geopackage to get corrupted. I hoped to get a
> warning or simply not be able to enter edit mode (We later found out, that
> the corrupted geopackage could be recoveredby by adding a new table, this
> somehow fixed it. Whew!).
>
> Worse, I found that the same thing happens, when I open a QGIS project
> with a layer from a geopackage for display only (no edit mode), which is
> being edited by an other user on an other computer. Again, both QGIS
> application crashed immediately with data loss. Again, the non-responsive
> QGIS tasks could not be killed by windows taskmanager, only by restarting
> of the computers.
>
> We are using QGIS 3.12.2 on Windows 10. The Geopackages are located on a
> samba network share.
>
> My questions:
>
> 1. Is this setup that bad? Do you experience the same fatal consequences
> if someone loads a layer from a geopackage which is being edited by someone
> else? Is there something I do wrong or I that can do to improve the
> situation?
>
> 2. I realize, that we should probably move from geopackage to a database.
> Do we need PostGIS or can we use PostgreSQL? We don't need more
> functinality than a geopackage offers (exept multi user read/edit
> possibility and stability).
>
> Many thanks for some hints that put me in the right direction!
>
> Bruno
>
> ___
> Qgis-user mailing listqgis-u...@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
>
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] Handling a large number of raster layers with Qgis architectural limitations

2019-11-18 Thread Jésahel Benoist
From my experience, GeoTIFF has a long history and is a more
appropriate format to handle multiple large rasters. As a container,
it could handle misc compression format (JPEG an other), misc
representation at different scales (resolution is not a problem), misc
color modes with raster/vectorial alpha layer, and so on. In one of my
projects I handle more than 400 raster files (4000x4000x32) without
any problem.
Of course, a better and final choice would be to tile everything, but
it is sometimes difficult with older maps.

Le lun. 18 nov. 2019 à 10:12, Patrick Dunford
 a écrit :
>
> Good day to all
>
> One of the user experiences I have had from using the Qgis software has been 
> with projects using large numbers of raster tile layers. These layers are 
> generally tiles that have a size of 4800x7200 pixels in GeoJPEG format and 
> have either been downloaded directly from tile servers to these locally 
> stored files, or created from downloaded tiles with other layers overlaid in 
> Gimp projects.
>
> There appears to be some architectural limit in Qgis desktop software 
> relating to either the total number of raster layer [files] in a project or 
> to the total number of pixels in raster layer [files] in a project. This is 
> unrelated to the number of layers or pixels currently enabled for display in 
> the map canvas. In practice, the appearance of this limit is that it is 
> kicking in long before the host computer's own physical resources are 
> anywhere near fully engaged. Map digitising and editing is done on systems 
> with 32 GB of physical memory (RAM) and 200 GB of SSD-based virtual memory 
> (swap) and these systems are able to edit very large Gimp projects for user 
> tile creation that often engage all of the system's physical memory and 
> around 100 GB of the virtual memory without problems. But these types of 
> numbers are in practice never seen with Qgis projects when the raster layer 
> limit is being seen.
>
> The appearance of a raster layer limit is generally experienced in older 
> versions of the software by layers being displayed on the canvas as garbage, 
> and in newer versions by the software crashing. It will only start working 
> again if raster layers are removed from the project. However, when layers are 
> loaded from WMTS servers, no appearance of limitation is seen.
>
> The question to be answered, then, is which of any possible range of 
> resolutions would be appropriate or useful to this predicament. With only 
> limited understanding of the architectural design of the software, it would 
> seem the following options exist:
>
> File a bug report for the software concerning a possible issue with the 
> design of the product
> Amalgamate smaller tiles into larger ones (e.g. 48 tiles at 4800x7200 can be 
> put into one tile at 57600x28800). This only works if the software issue is 
> related to the number of file based tile layers and not to the total number 
> of pixels in those layers.
> Post a feature request for sub-project capabilities. This would allow a 
> project that combines vector and raster layers, to be split into one project 
> containing the vector layers and a number of projects each of which contains 
> the vector project as a subproject and a certain subset of all the raster 
> layers that is smaller than the observable limit.
> Set up my own local WMTS server to serve all the raster layers to my map 
> editing projects.
> Explore the possibilities of preconfigured limits in the operating system 
> that may need to be increased to overcome file based layer limits in projects 
> (such as the NOFILES limit in Linux, currently set at 10,000 hard and soft on 
> map editing computers)
>
> Is anyone who is knowledgeable about the architecture of the Qgis desktop 
> software able to comment with some detail about possible resolutions.
>
>
> ___
> Qgis-user mailing list
> Qgis-user@lists.osgeo.org
> List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
> Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

[Qgis-user] Little expression builder bug ?

2019-11-04 Thread Jésahel Benoist
In the expression builder, when the field contains a '/' char (please don't
ask me why someone had this bad idea, I don't know), the "Load top 10
unique values" and "Load all unique values" doesn't work.


https://i.imgur.com/CGJPpES.png

Regards,

djes
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user

Re: [Qgis-user] GeoPackage deadlocks

2019-10-25 Thread Jésahel Benoist
I could provide some background information as we're working for about a
year in a multi-users (5 users) configuration mainly based on network
shared geopackages in a Windows environment. I've tried and tested a lot of
configurations and still looking for a near PostGIS solution only in terms
of easiness and security.

At first, we were using SQLite and I have to say that it was good,
especially in terms of speed. But it lacked the possibility to alter
database schema, which was a pain.
So I switched to Geopackage and very bad problems started.
First as you all know was the speed problem. Sometimes, it was just
unusable with only two users, and sometimes even with only one user,
especially with big database, with some display locks. I discovered that
the drawing by itself was like a concurrent user... Disabling the drawing
restored usage, even if sometimes it needed to restart qgis.
Then I discovered the wal problem and switched to delete mode. Speed
problem was gone but... I got a file lock. One of my db file was then
unusable. I had to restore it. Happily it was with the most experienced
user and at the end of the day, and we had only one session data lost.
So I decided to divide the biggest db to several little files and to make
apply stricter usage rules to users to be sure that there isn't much
concurrent access.
For now it's usable but we still have to restart qgis sometimes. Sometimes
the display disappears and reappears with a delay or by creating an entity.
Note that it's the same with SQLite.

As a coder, I wonder why there isn't always a file locking mechanism with a
threaded waiting loop, even for read access and for all file formats,
because if you change the file content, nothing can say a read wasn't done
at the same time, and so the read could obtain bad values. Even multiple
threads on a single machine could access the same file anytime, so it would
be safer to avoid this kind of problem.

I do love QGIS and would be really happy to help, if I can, with my modest
capabilities.

Best regards,

Jésahel
___
Qgis-user mailing list
Qgis-user@lists.osgeo.org
List info: https://lists.osgeo.org/mailman/listinfo/qgis-user
Unsubscribe: https://lists.osgeo.org/mailman/listinfo/qgis-user