Re: [OSM-dev] OSM Database schema

2020-01-04 Thread Martin Koppenhoefer


sent from a phone

> On 4. Jan 2020, at 17:28, Jean Marie Falisse  wrote:
> 
> Is it still true that in the OSM database, areas are not represented as such?


areas can be represented as areas through multipolygon relations which are 
always areas or by help of an additional tag (area=yes/no), or through 
plausibility (tags and their combinations may imply an area or not). There 
isn’t a dedicated area object, maybe this is what you meant. Areas are 
represented with ways, and tags or relations are required to define the ways as 
areas.


> That would mean, for instance, that a pedestrian zone, let’s say a big square 
> in a city, cannot be made to be crossed diagonally when used in a route 
> planner. Am I right?


typically routing engines operate on graphs, i.e. they do not route diagonally 
across areas, but this isn’t related to the question whether there is a 
dedicated datatype for areas or not.

Cheers Martin 
___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] Malformed API results

2020-01-04 Thread mmd
On 2020-01-04 21:38, Mike Parfitt wrote:
> What does curl and wget return for you ?

Here's the result I got when running:
 curl https://api.openstreetmap.org/api/0.6/user/gpx_files -u
"some_osm_user_name"


http://www.openstreetmap.org/copyright";
license="http://opendatacommons.org/licenses/odbl/1-0/";>

  ...


  ...


  ...

...



You need to replace the user name with your own here, and provide a
password when curl asks you to. The result is an XML document with a
number of gpx_file elements. Note that I replaced some of the field
contents with dummy values above.


-- 




___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] OSM Database schema

2020-01-04 Thread Mateusz Konieczny
AFAIK it never started and it was always at stage "it would be nice if someone 
would do something,
for example write some plan how this upgrade would be coordinated".

4 Jan 2020, 19:38 by fa003...@skynet.be:

> Ok, thanks.
>
> Does that also mean that this Area datatype task in “> 
> https://wiki.openstreetmap.org/wiki/Top_Ten_Tasks> ” is abandoned?
>
> Jean Marie Falisse
>
>
>
>> Le 4 janv. 2020 à 19:18, Stefan Keller <>> sfkel...@gmail.com>> > a écrit :
>>
>> Am Sa., 4. Jan. 2020 um 18:18 Uhr schrieb mmd <>> mmd@gmail.com>> >:
>>
>>> ... As an example check out:
>>> https://wiki.openstreetmap.org/wiki/User:Maxbe/Routen_%C3%BCber_Fl%C3%A4chen
>>>
>>
>> See also the research work from my lab >> https://eprints.hsr.ch/625/>>  and
>> https://github.com/PlazaRoute/plazaroute>>  .
>>
>> :Stefan
>>
>> Am Sa., 4. Jan. 2020 um 18:18 Uhr schrieb mmd <>> mmd@gmail.com>> >:
>>
>>>
>>> On 2020-01-04 17:22, Jean Marie Falisse wrote:
>>>
 that a pedestrian zone, let’s say a big square in a city, cannot be made
 to be crossed diagonally when used in a route planner.

>>>
>>> Getting a bit off topic here... You can calculate some artificial ways
>>> and feed that into some router. As an example check out:
>>> https://wiki.openstreetmap.org/wiki/User:Maxbe/Routen_%C3%BCber_Fl%C3%A4chen
>>>
>>> --
>>>
>>>
>>>
>>> ___
>>> dev mailing list
>>> dev@openstreetmap.org
>>> https://lists.openstreetmap.org/listinfo/dev
>>>
>>
>> ___
>> dev mailing list
>> dev@openstreetmap.org
>> https://lists.openstreetmap.org/listinfo/dev
>>

___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] Malformed API results

2020-01-04 Thread Mike Parfitt
Hi, thanks for the reply.

On my android tablet :-

. . the following browsers exhibit the same problem :-
. . . . Chrome
. . . . Opera
. . . . Samsung's basic offering

. . so does the http shortcuts app

I am not an Android/Linux command line user.  I did install a command line app 
and executed the curl command prepared by the http shortcuts app, but all I got 
was "not found".

The same stream of description tags values precedes the desired xml on a 
Windows 10 Home PC using the Edge and Chrome browsers.

My conclusion is that it isn't a browser artifact.

Have you uploaded any gpx files ?  What does curl and wget return for you ?

From: mmd 
Sent: 04 January 2020 11:31:15
To: dev@openstreetmap.org 
Subject: Re: [OSM-dev] Malformed API results

On 2019-12-13 19:09, Mike Parfitt wrote:
> The https://api.openstreetmap.org/api/0.6/user/gpx_files call returns a
> long stream of  tag values before the xml that it is
> supposed to return.

That's most likely a browser artifact and has nothing to do with the
actual data returned by the API. Try curl or wget instead and inspect
the resulting XML file in a text editor.

--



___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev
___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] OSM Database schema

2020-01-04 Thread Jean Marie Falisse
Ok, thanks.

Does that also mean that this Area datatype task in 
“https://wiki.openstreetmap.org/wiki/Top_Ten_Tasks” is abandoned?

Jean Marie Falisse


> Le 4 janv. 2020 à 19:18, Stefan Keller  a écrit :
> 
> Am Sa., 4. Jan. 2020 um 18:18 Uhr schrieb mmd :
>> ... As an example check out:
>> https://wiki.openstreetmap.org/wiki/User:Maxbe/Routen_%C3%BCber_Fl%C3%A4chen
> 
> See also the research work from my lab https://eprints.hsr.ch/625/ and
> https://github.com/PlazaRoute/plazaroute .
> 
> :Stefan
> 
> Am Sa., 4. Jan. 2020 um 18:18 Uhr schrieb mmd :
>> 
>> On 2020-01-04 17:22, Jean Marie Falisse wrote:
>>> that a pedestrian zone, let’s say a big square in a city, cannot be made
>>> to be crossed diagonally when used in a route planner.
>> 
>> Getting a bit off topic here... You can calculate some artificial ways
>> and feed that into some router. As an example check out:
>> https://wiki.openstreetmap.org/wiki/User:Maxbe/Routen_%C3%BCber_Fl%C3%A4chen
>> 
>> --
>> 
>> 
>> 
>> ___
>> dev mailing list
>> dev@openstreetmap.org
>> https://lists.openstreetmap.org/listinfo/dev
> 
> ___
> dev mailing list
> dev@openstreetmap.org
> https://lists.openstreetmap.org/listinfo/dev

___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] OSM Database schema

2020-01-04 Thread Stefan Keller
Am Sa., 4. Jan. 2020 um 18:18 Uhr schrieb mmd :
> ... As an example check out:
> https://wiki.openstreetmap.org/wiki/User:Maxbe/Routen_%C3%BCber_Fl%C3%A4chen

See also the research work from my lab https://eprints.hsr.ch/625/ and
https://github.com/PlazaRoute/plazaroute .

:Stefan

Am Sa., 4. Jan. 2020 um 18:18 Uhr schrieb mmd :
>
> On 2020-01-04 17:22, Jean Marie Falisse wrote:
> > that a pedestrian zone, let’s say a big square in a city, cannot be made
> > to be crossed diagonally when used in a route planner.
>
> Getting a bit off topic here... You can calculate some artificial ways
> and feed that into some router. As an example check out:
> https://wiki.openstreetmap.org/wiki/User:Maxbe/Routen_%C3%BCber_Fl%C3%A4chen
>
> --
>
>
>
> ___
> dev mailing list
> dev@openstreetmap.org
> https://lists.openstreetmap.org/listinfo/dev

___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] OSM Database schema

2020-01-04 Thread mmd
On 2020-01-04 17:22, Jean Marie Falisse wrote:
> that a pedestrian zone, let’s say a big square in a city, cannot be made
> to be crossed diagonally when used in a route planner.

Getting a bit off topic here... You can calculate some artificial ways
and feed that into some router. As an example check out:
https://wiki.openstreetmap.org/wiki/User:Maxbe/Routen_%C3%BCber_Fl%C3%A4chen

-- 



___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] OSM Database schema

2020-01-04 Thread Jean Marie Falisse
Hi,

Best wishes to all !

I am new to this list.

Lorenzo, I will be very interested in reading the result of your work.

Is it still true that in the OSM database, areas are not represented as such? 
That would mean, for instance, that a pedestrian zone, let’s say a big square 
in a city, cannot be made to be crossed diagonally when used in a route 
planner. Am I right?

That would mean, Dear Lorenzo, that you are 🤣 a designated volunteer for the 
database overhaul project !  See Area datatype on 
“https://wiki.openstreetmap.org/wiki/Top_Ten_Tasks”.

Just kidding. Still, I wouldn’t mind to be involved in this, especially if some 
programs could be written in the most beautiful programming language ever, 
Haskell of course. What you can do with this beast is just awesome.

Hope I didn’t disturb too much. Put it on the account of the enthusiasm of the 
youth!  😂  Thanks for reading.

JMF


Jean Marie Falisse
Berensheide, 3
B 1170 Watermael-Boitsfort
Belgique
+32 2 673 32 22
+32 479 509899
jmfali...@acm.org
http://member.acm.org/~jmfalisse

> Le 4 janv. 2020 à 11:40, mmd  a écrit :
> 
> On 2020-01-04 09:59, Lorenzo Stucchi wrote:
>> Thank you Pascal. This is can be more precise than just I looking at the
>> visualisation [1].
> 
> I'm not aware of a comprehensive data model internals documentation
> beyond the actual source code in
> https://github.com/openstreetmap/openstreetmap-website, in particular
> the app/*/api directory
> 
>> 
>> But, for example, what is the “timestamp” in the “node" table? 
> 
> It refers to the current time in UTC when the node create/update/delete
> operation was executed. Please see
> https://github.com/openstreetmap/openstreetmap-website/blob/master/app/models/node.rb#L243
> 
> 
>> And what is the “redactions” table? 
> 
> It contains a list of reasons why an object has been redacted, see
> https://www.openstreetmap.org/redactions - the actual objects (such as
> nodes, ways, relations) refer to this redaction table via the redaction_id.
> 
>> Or, why in the “way_nodes” table there is
>> “version", but also it is just a link to the “nodes” table that contains
>> also the “version” attribute.
> 
> Basically there are two different sets of tables: the current_* ones,
> and the historic ones. "way_nodes" belongs to the historic set of
> tables, and you need the version attribute to know that a node was part
> of say version 2 of way 12345. On the other hand, the current_way_nodes
> table has no version attribute, as it assumes that it refers to the
> latest version of an object.
> 
>> 
>> For this reason, I was trying to look to an explanation of this schema
>> if it exists.
> 
> I think one good way to find out more about those different tables is to
> install a local version of the Rails port and do some edits via
> iD/JOSM/Potlatch. The Rails port is quite verbose and lists every single
> database operation on the console.
> 
> 
> -- 
> 
> 
> ___
> dev mailing list
> dev@openstreetmap.org
> https://lists.openstreetmap.org/listinfo/dev

___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] Malformed API results

2020-01-04 Thread mmd
On 2019-12-13 19:09, Mike Parfitt wrote:
> The https://api.openstreetmap.org/api/0.6/user/gpx_files call returns a
> long stream of  tag values before the xml that it is
> supposed to return. 

That's most likely a browser artifact and has nothing to do with the
actual data returned by the API. Try curl or wget instead and inspect
the resulting XML file in a text editor.

-- 



___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] OSM Database schema

2020-01-04 Thread mmd
On 2020-01-04 09:59, Lorenzo Stucchi wrote:
> Thank you Pascal. This is can be more precise than just I looking at the
> visualisation [1].

I'm not aware of a comprehensive data model internals documentation
beyond the actual source code in
https://github.com/openstreetmap/openstreetmap-website, in particular
the app/*/api directory

> 
> But, for example, what is the “timestamp” in the “node" table? 

It refers to the current time in UTC when the node create/update/delete
operation was executed. Please see
https://github.com/openstreetmap/openstreetmap-website/blob/master/app/models/node.rb#L243


> And what is the “redactions” table? 

It contains a list of reasons why an object has been redacted, see
https://www.openstreetmap.org/redactions - the actual objects (such as
nodes, ways, relations) refer to this redaction table via the redaction_id.

 > Or, why in the “way_nodes” table there is
> “version", but also it is just a link to the “nodes” table that contains
> also the “version” attribute.

Basically there are two different sets of tables: the current_* ones,
and the historic ones. "way_nodes" belongs to the historic set of
tables, and you need the version attribute to know that a node was part
of say version 2 of way 12345. On the other hand, the current_way_nodes
table has no version attribute, as it assumes that it refers to the
latest version of an object.

> 
> For this reason, I was trying to look to an explanation of this schema
> if it exists.

I think one good way to find out more about those different tables is to
install a local version of the Rails port and do some edits via
iD/JOSM/Potlatch. The Rails port is quite verbose and lists every single
database operation on the console.


-- 


___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] OSM Database schema

2020-01-04 Thread Lorenzo Stucchi
Thank you Pascal. This is can be more precise than just I looking at the 
visualisation [1].

But, for example, what is the “timestamp” in the “node" table? And what is the 
“redactions” table? Or, why in the “way_nodes” table there is “version", but 
also it is just a link to the “nodes” table that contains also the “version” 
attribute.

For this reason, I was trying to look to an explanation of this schema if it 
exists.

Thanks,
Stucchi Lorenzo

[1] https://wiki.openstreetmap.org/w/images/5/58/OSM_DB_Schema_2016-12-13.svg

Il giorno 4 gen 2020, alle ore 09:36, Pascal Neis 
mailto:pas...@neis-one.org>> ha scritto:

Maybe this is what you are searching for?
https://github.com/openstreetmap/openstreetmap-website/blob/master/db/structure.sql



Am 04.01.20 um 09:21 schrieb Lorenzo Stucchi:
Hi Stefan,
Thank you for your links, but I was searching for more detailed information. I 
knew how OpenStreetMap works, and I'm contributing by years.
I know how the basic database schema works and for this reason I wrote here to 
understood if someone has more detailed explanation of all the table that I 
sent in the first mail. My idea was to explain this table, but some names are 
not so clear. The general description of the database in different paper is 
base on the response of the API, but this is not the real structure of the 
database, so, for this reason, I was searching for this more detailed 
description.
Thanks,
Stucchi Lorenzo
Il giorno 3 gen 2020, alle ore 21:13, Stefan Keller  ha 
scritto:

Ciao Lorenzo

I assume you're interested in a software developers perspective.
For this I've found e.g. "An Introduction to OpenStreetMap" by Mele
Sax-Barnett 2014 [1].
This is a little outdated but seems to be a rather road online overview.
In order to be up-to-date replace following links there:
* ignore e.g. http://market.weogeo.com/  -  and replace with
https://osmaxx.hsr.ch/
* Replace TileMill -  with https://maputnik.github.io/
* Replace slide "The Future: Vector tiles"  - e.g. with
https://openmaptiles.org/

That's all incomplete and just scratching the surface.
So pls. read up first what OSM is and - before all - edit something in
OSM (e.g. building addresses or shops you know) in order to understand
how OSM works.

:Stefan

[1] http://pdxmele.com/intro-osm/OSM_intro_workshop.pdf

Am Fr., 3. Jan. 2020 um 16:36 Uhr schrieb Lorenzo Stucchi
:

Dear all,

For my master thesis, I will work with OpenStreetMap, and I would like to 
describe the database structure of OSM accurately.

I found at this page [1] an image that describes the schema of the database, 
but elements in the table are not described. Instead, I found in this page [2] 
a description of the Node element, but there are not all the elements present 
in the image [1].

Exist a page that describes all the database schema?

Thank you very much,
Stucchi Lorenzo


[1] https://wiki.openstreetmap.org/wiki/Rails_port/Database_schema
[2] https://wiki.openstreetmap.org/wiki/Node
___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev
___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev


Re: [OSM-dev] OSM Database schema

2020-01-04 Thread Lorenzo Stucchi
Hi Stefan,

Thank you for your links, but I was searching for more detailed information. I 
knew how OpenStreetMap works, and I'm contributing by years. 

I know how the basic database schema works and for this reason I wrote here to 
understood if someone has more detailed explanation of all the table that I 
sent in the first mail. My idea was to explain this table, but some names are 
not so clear. The general description of the database in different paper is 
base on the response of the API, but this is not the real structure of the 
database, so, for this reason, I was searching for this more detailed 
description.

Thanks,
Stucchi Lorenzo


> Il giorno 3 gen 2020, alle ore 21:13, Stefan Keller  ha 
> scritto:
> 
> Ciao Lorenzo
> 
> I assume you're interested in a software developers perspective.
> For this I've found e.g. "An Introduction to OpenStreetMap" by Mele
> Sax-Barnett 2014 [1].
> This is a little outdated but seems to be a rather road online overview.
> In order to be up-to-date replace following links there:
> * ignore e.g. http://market.weogeo.com/  -  and replace with
> https://osmaxx.hsr.ch/
> * Replace TileMill -  with https://maputnik.github.io/
> * Replace slide "The Future: Vector tiles"  - e.g. with
> https://openmaptiles.org/
> 
> That's all incomplete and just scratching the surface.
> So pls. read up first what OSM is and - before all - edit something in
> OSM (e.g. building addresses or shops you know) in order to understand
> how OSM works.
> 
> :Stefan
> 
> [1] http://pdxmele.com/intro-osm/OSM_intro_workshop.pdf
> 
> Am Fr., 3. Jan. 2020 um 16:36 Uhr schrieb Lorenzo Stucchi
> :
>> 
>> Dear all,
>> 
>> For my master thesis, I will work with OpenStreetMap, and I would like to 
>> describe the database structure of OSM accurately.
>> 
>> I found at this page [1] an image that describes the schema of the database, 
>> but elements in the table are not described. Instead, I found in this page 
>> [2] a description of the Node element, but there are not all the elements 
>> present in the image [1].
>> 
>> Exist a page that describes all the database schema?
>> 
>> Thank you very much,
>> Stucchi Lorenzo
>> 
>> 
>> [1] https://wiki.openstreetmap.org/wiki/Rails_port/Database_schema
>> [2] https://wiki.openstreetmap.org/wiki/Node
>> ___
>> dev mailing list
>> dev@openstreetmap.org
>> https://lists.openstreetmap.org/listinfo/dev


___
dev mailing list
dev@openstreetmap.org
https://lists.openstreetmap.org/listinfo/dev