Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [sumo-user] Problem while importing shape file and creating TAZ

Hello,
for some reason the option --shapefile.guess-projection was not successful.
You can import the shapefile using the following options:
polyconvert --net-file osm.net.xml --shapefile-prefixes Example_Shape_Files/Export_Output_3 --shapefile.id-column FID_MD_SMZ ---proj.utm

note:
- option --proj.utm sets the correct projection
- osm.net.xml contains UTM coordinates which are shifted towards 0,0 to improve numerical stability. By passing the net.xml to polyconvert, the same shift is applied to the polygons.
- to improve visibility in the gui it is helpful to also add the polyconvert option "--shapefile.fill false" (this will generate only the outlines instead of  filled shapes)

regards,
Jakob


2017-11-29 6:29 GMT+01:00 Vrinda Khirwadkar (vkhrwdkr) <vkhrwdkr@xxxxxxxxxxx>:

Hello Jakob,

Thank you for your feedback. As suggested, I tried using Polyconvert to generate poi.xml file. I was able to generate the same. But the tool edgesInDistricts takes two inputs, one is the network input and other one is the polygon xml. The network input is extracted from OpenStreetMap for approximately the same area as shape file . osm.net.xml and polygon xml  were fed as input to the tool edgesInDistricts.  I am attaching xml output from polyconvert. Please suggest the way further.

Command --
>edgesInDistricts.py -n "C:\Users\Bhushan\Documents\ArcGIS\Example_Prince George\osm.net.xml" -t "C:\Users\Bhushan\Documents\ArcGIS\Example_Prince George\shp.poi.xml" -o "C:\Users\Bhushan\Documents\ArcGI
S\Example_Prince George\shp.taz.xml"

I found an assertion error as mentioned below:
Traceback (most recent call last):
  File "C:\Program Files (x86)\DLR\Sumo\tools\edgesInDistricts.py", line 188, in
 <module>
    reader.computeWithin(polyReader.getPolygons(), options)
  File "C:\Program Files (x86)\DLR\Sumo\tools\edgesInDistricts.py", line 44, in
computeWithin
    districtBoxes[district.id] = district.getBoundingBox()
  File "C:\Program Files (x86)\DLR\Sumo\tools\sumolib\shapes\polygon.py", line 4
7, in getBoundingBox
    assert(xmin != xmax or ymin != ymax)
AssertionError


Also, regarding item 1 in previous post (mentioned below) , how can we generate a network using the shape files? I am attaching the required shapefile for reference.
First problem here is that when I try to use these shape files, I cannot find any reference to street id, from id (name of the node the edge starts at) and to id (name of the node the edge ends at) which are required when using netconvert command with shape files (http://sumo.dlr.de/wiki/Networks/Import/ArcView). Can you please guide how to generate a network with given shape files?



Vrinda Khirwadkar

University of Memphis




From: sumo-user-bounces@xxxxxxxxxxx <sumo-user-bounces@xxxxxxxxxxx> on behalf of sumo-user-request@xxxxxxxxxxx <sumo-user-request@xxxxxxxxxxx>
Sent: Monday, November 27, 2017 12:27 AM
To: sumo-user@xxxxxxxxxxx
Subject: sumo-user Digest, Vol 5, Issue 44
 
Send sumo-user mailing list submissions to
        sumo-user@xxxxxxxxxxx

To subscribe or unsubscribe via the World Wide Web, visit
        https://dev.eclipse.org/mailman/listinfo/sumo-user
or, via email, send a message with subject or body 'help' to
        sumo-user-request@xxxxxxxxxxx

You can reach the person managing the list at
        sumo-user-owner@xxxxxxxxxxx

When replying, please edit your Subject line so it is more specific
than "Re: Contents of sumo-user digest..."


Today's Topics:

   1. Problem while importing shape file and creating TAZ
      (Vrinda Khirwadkar (vkhrwdkr))
   2. Re: influencing lane change behavior in accordance with road
      marks (Jakob Erdmann)
   3. Re: Problem while importing shape file and creating TAZ
      (Jakob Erdmann)
   4.  Automated Intersections (Eugene Vinitsky via sumo-user)


----------------------------------------------------------------------

Message: 1
Date: Sun, 26 Nov 2017 23:11:28 +0000
From: "Vrinda Khirwadkar (vkhrwdkr)" <vkhrwdkr@xxxxxxxxxxx>
To: "sumo-user@xxxxxxxxxxx" <sumo-user@xxxxxxxxxxx>
Subject: [sumo-user] Problem while importing shape file and creating
        TAZ
Message-ID:
        <BN3PR04MB2306B4DFDA40A03B6A654FFECA240@BN3PR04MB2306.namprd04.prod.outlook.com>
       
Content-Type: text/plain; charset="iso-8859-1"

Hello All,


I am a new user of this tool and found very useful in my current graduate research.

I am trying to build below scenario but not able to proceed ahead. I am using Sumo 0.31.0 version.

  1.  Import real world shape files (Geometry type: Polygon) with 6 distinct zones.
  2.  Import corresponding OD Matrices to generate traffic demand using od2trips.exe.


First problem here is that when I try to use these shape files, I cannot find any reference to street id, from id (name of the node the edge starts at) and to id (name of the node the edge ends at) which are required when using netconvert command with shape files (http://sumo.dlr.de/wiki/Networks/Import/ArcView). Can you please guide how to generate a network with given shape files?


Second problem is that for using od2trips.exe, we need to provide TAZ.XML file with taz_id and corresponding edge id in each zones. Right now I tried to create this input XML file manually and able to generate trips. However, this is not possible to generate this file manually if network is large. Is there any existing tool/script to generate TAZ XML from given shape file (geometry type: Polygon).


Do let me know if you need to view shape files.

Please guide.


Thanks in advance.

Vrinda Khirwadkar

University of Memphis
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://dev.eclipse.org/mailman/private/sumo-user/attachments/20171126/a96da1a0/attachment.html>

------------------------------

Message: 2
Date: Mon, 27 Nov 2017 09:18:00 +0100
From: Jakob Erdmann <namdre.sumo@xxxxxxxxxxxxxx>
To: Sumo project User discussions <sumo-user@xxxxxxxxxxx>
Cc: Richter Gerald <Gerald.Richter@xxxxxxxxx>
Subject: Re: [sumo-user] influencing lane change behavior in
        accordance with road marks
Message-ID:
        <CAMbUcbxHLbJnNMLArDwgBmBPgzXheFcR24MFN8L3qPCzd_8cAg@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

Hello,
in the latest development version, the MSLaneChanger constuctor already
sets a flag for each lane which defines whether changing to the left or
right is possible.
I've outlined a rough implementation draft here:
https://github.com/DLR-TS/sumo/issues/3656
use lane information to set MSLaneChanger::ChangeElem::mayChangeRight and mayChangeLeft flags when no neigh (or only opposite neigh) are defined, all directions are allowed when at least one lane ...


Patches are welcome (-:
regards,
Jakob


2017-11-24 21:40 GMT+01:00 Michael Behrisch <oss@xxxxxxxxxxx>:

> Hi Gerald,
> the solid line mark case can be solved either by separating into two
> separate edges or by introducing a very narrow lane which forbids all
> vehicles (the latter is probably better).
> For the asymmetric case it is a little harder. We introduced the concept
> of defining neighboring lanes explicitly in a network which we needed
> for the opposite direction driving but I am pretty sure, this cannot be
> used yet to limit the lane neighbors for lanes of the same edge. But if
> I wanted to implement something I would follow this path. For an
> impression how this looks in the net:
> https://github.com/DLR-TS/sumo/blob/master/tests/sumo/
sumo - SUMO is an open source, highly portable, microscopic and continuous road traffic simulation package designed to handle large road networks. It allows for intermodal simulation including pede...


> opposite_direction_driving/net.net.xml
>
> Best regards,
> Michael
>
> Am 24.11.2017 um 17:38 schrieb Richter Gerald:
> > Dear list,
> >
> > when importing from open drive I encounter the problem of roadMark
> > elements,
> > which are present in the xodr file, but not mapped to the converted net
> > file.
> > - I guess this can be implemented in the Importer and is a problem with
> > some discernible solution down the road.
> >
> > BUT:
> > * how would I map the behavior resulting from solid line marks between
> > lanes
> >      onto the net attributes of SUMO ?
> > * how would I do that for an asymmetric case of one broken and one solid
> > line next to each other,
> >      allowing vehicles to change lanes in just 1 direction ?
> >
> > thanks,
> > Gerald.
> >
> > _______________________________________________
> > sumo-user mailing list
> > sumo-user@xxxxxxxxxxx
> > To change your delivery options, retrieve your password, or unsubscribe
> from this list, visit
> > https://dev.eclipse.org/mailman/listinfo/sumo-user
Mailing list: sumo-user Sumo project User discussions About sumo-user Sumo project User discussions


> >
>
>
>
> _______________________________________________
> sumo-user mailing list
> sumo-user@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or unsubscribe
> from this list, visit
> https://dev.eclipse.org/mailman/listinfo/sumo-user
Mailing list: sumo-user Sumo project User discussions About sumo-user Sumo project User discussions


>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://dev.eclipse.org/mailman/private/sumo-user/attachments/20171127/e3e602f1/attachment.html>

------------------------------

Message: 3
Date: Mon, 27 Nov 2017 09:26:44 +0100
From: Jakob Erdmann <namdre.sumo@xxxxxxxxxxxxxx>
To: Sumo project User discussions <sumo-user@xxxxxxxxxxx>
Subject: Re: [sumo-user] Problem while importing shape file and
        creating TAZ
Message-ID:
        <CAMbUcbygYKF-G6SsDPPYVLV6GWiX5NL0EJW+ULBBmJjg6hPahg@xxxxxxxxxxxxxx>
Content-Type: text/plain; charset="utf-8"

Hello,
the tool edgesInDistricts (
http://sumo.dlr.de/wiki/Tools/District#edgesInDistricts.py) can be used to
edgesInDistricts.py. Parsing a number of networks and taz (district) files with shapes this script writes a taz file with all the edges which are inside the relevant taz.


generated the TAZ files automatically from polygons.
The polygons must be in the xml format generated by Polyconvert and
describe the outline of the TAZ.
regards,
Jakob

2017-11-27 0:11 GMT+01:00 Vrinda Khirwadkar (vkhrwdkr) <vkhrwdkr@xxxxxxxxxxx
>:

> Hello All,
>
>
> I am a new user of this tool and found very useful in my current graduate
> research.
>
> I am trying to build below scenario but not able to proceed ahead. I am
> using Sumo 0.31.0 version.
>
>
>    1. Import real world shape files (Geometry type: Polygon) with 6
>    distinct zones.
>    2. Import corresponding OD Matrices to generate traffic demand using
>    od2trips.exe.
>
>
> First problem here is that when I try to use these shape files, I cannot
> find any reference to street id, from id (name of the node the edge
> starts at) and to id (name of the node the edge ends at) which are
> required when using netconvert command with shape files (
> http://sumo.dlr.de/wiki/Networks/Import/ArcView). Can you please guide
NETCONVERT is able to directly read binary ArcView databases ("shapefiles"). To convert such databases, at least three files are needed: a file with the extension ...


> how to generate a network with given shape files?
>
>
> Second problem is that for using od2trips.exe, we need to provide TAZ.XML
> file with taz_id and corresponding edge id in each zones. Right now I tried
> to create this input XML file manually and able to generate trips. However,
> this is not possible to generate this file manually if network is large. Is
> there any existing tool/script to generate TAZ XML from given shape file
> (geometry type: Polygon).
>
>
> Do let me know if you need to view shape files.
>
> Please guide.
>
>
> Thanks in advance.
>
> Vrinda Khirwadkar
>
> University of Memphis
>
> _______________________________________________
> sumo-user mailing list
> sumo-user@xxxxxxxxxxx
> To change your delivery options, retrieve your password, or unsubscribe
> from this list, visit
> https://dev.eclipse.org/mailman/listinfo/sumo-user
Mailing list: sumo-user Sumo project User discussions About sumo-user Sumo project User discussions


>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://dev.eclipse.org/mailman/private/sumo-user/attachments/20171127/353dafb9/attachment.html>

------------------------------

Message: 4
Date: Mon, 27 Nov 2017 00:47:57 +0000
From: Eugene Vinitsky via sumo-user <sumo-user@lists.sourceforge.net>
To: sumo-user <sumo-user@lists.sourceforge.net>
Subject: [sumo-user]  Automated Intersections
Message-ID:
        <CAMUzCBn7A37u4+WhmNv5Cmz=JFnbS5ziqmKjJ1VKdmRpi+zfeg@mail.gmail.com>
Content-Type: text/plain; charset="us-ascii"

Hello,

I am trying to use SUMO to control an automated intersection. If I set the
priorities of a node that two lanes pass through to be equal, one of the
lanes yields to the other. If I set the mode to be "unregulated" the cars
wind up passing through each other. Does anyone know what mode might be
best for this purpose or do I need to write my own code to detect crashes?

Thank you,

Eugene Vinitsky
------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
sumo-user mailing list
sumo-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/sumo-user


------------------------------

_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/sumo-user
Mailing list: sumo-user Sumo project User discussions About sumo-user Sumo project User discussions




End of sumo-user Digest, Vol 5, Issue 44
****************************************

_______________________________________________
sumo-user mailing list
sumo-user@xxxxxxxxxxx
To change your delivery options, retrieve your password, or unsubscribe from this list, visit
https://dev.eclipse.org/mailman/listinfo/sumo-user



Back to the top