Consider a simple network file with 2 edges (1, 2) [edge example] and the flow direction is from (1) to (2). I want to find a way to reverse the direction of flow using NETEDIT i.e. (2) to (1).
P.S. I want to find a way to do this using NETEDIT because I am editing a 100mb network data and it would be impossible for me to change the edge direction individually.
Thanks in advance!
Go into select mode and select all the edges you want to revert. Then right click on an edge and select Edge operations-> reverse edge. For reverting a single edge you can skip the selection step.
Related
I have a layout defined for agents to move from one rectangular node to another, based on a list in a database. So for example, agent 1 will go to 'lane' 701, then on to 702, etc.
The layout looks like this:
example of layout
The agents move enter from the top left, along the x to the end of that row, then down to the bottom and out to the right, visiting the 'lanes' on their way.
However, I've noticed that one agent has its first lane in the bottom right so rather than following the path across and then down, it's using the shortest distance and moving on the diagonal straight to the lane in the corner:
movement behaviour
Is there something in the software that I can set to strictly follow the paths set? I cannot work out why the agent is breaking the path so I can only assume it's something I am missing.
in the first place, your agent is doing this diagonal probably because you have 2 different networks... if your destination is not in the current network, then the agent will use the shortest distance to the destination, which seems to be your case.
On the other hand, you can't control how the agents move on your network, and it will always take the shortest path or some optimized option... in order to make them follow the path you want, you need to generate intermediary destinations.
I use unity official asset probuilder
see my gif, I select hold 4 vertexes, I hope create new face so I click "Fill Hole", but not face is created
I've never used probuilder, but in other 3d max app you will need to delete the inner polygons that to be able to cap that face. select all the polygons in the "well" and delete, you will now have a hole to fill
[GIF]
[]1
update
I find a complex but accurate way to do this
unity editor > Tools > Probuilder > editor > open vertex position editor
when i select vertex, position editor
put selected positions to txt file
unity editor > tools > probuilder > editor > open new shape editor > shape selector > custom
build face with positions in txt
attention: "Custom" point order is very strange, for ex, "Custom" to build cube, the point order is, top-left, top-right, bottom-left, bottom-right, in my understanding, the correct order is:
in x-z axis face, image put point in Scene to build more near "parallel" x axis edge
put edge point from x axis < 0(left) side to x axis > 0(right) side, and then use same way to build other "parallel" x axis edge
select my created face and old object, probuilder toolbar > Merge Objects to merge them into one
above way I use do all with ProBuilder API since it's opensource but not document, but filling face is rare case, so I think do it in probuilder gui is enongh
old answer
my tmp solution is use probuilder > New Poly Shape to use mouse click 4 vertexs and manually make face, but it's not perfect, it has seam in edge
As of probuilder 4, you can achieve this very quickly without using 'fill hole'. Fill Hole is useful, but not for this.
Enter edge select mode and select an edge containing two of the vertices you wish to make a face out of.
Extrude the edge (ctrl + e or 'extrude edges') to the general area of the third vertex.
Enter vertex select mode and select the third vertex, then the two vertices from step two and any others you want to add.
Click the collapse vertices button and ensure "Collapse at first" is enabled (it will stay enabled until you disable it). The shortcut is alt + C.
You can also use this technique & the alt+c ctrl+e keys to quickly weld coincident vertices and quickly draft complex level geometry. You can also use this to quickly bridge edges even if they have a different vertex count.
With the Probuilder API, you can easily make an editor script to automate this process & assign a special shortcut to it. If you can operate the Unity API, you can operate the probuilder API.
I am using SUMO to simulate the LuST scenario from https://github.com/lcodeca/LuSTScenario. However, since the scenario is rather large, I would like to start with a simulation constrained to region of interest. Is there a straight forward way to select such a region and have vehicles only simulated in that part of the map?
You can crop the network either using netedit by selecting the region of interest (change to select mode and then draw a rectangle holding the shift key), then inverting the selection (invert button) and deleting the rest. Or if you already know the boundaries or the edges you want to keep you can use for instance with netconvert --keep-edges.in-boundary minX,minY,maxX,maxY -s large.net.xml -o small.net.xml. See here for more netconvert options.
The next step is cutting the routes, which usually means a call like this:
$SUMO_HOME/tools/route/cutRoutes.py small.net.xml large.rou.xml --routes-output small.rou.xml --orig-net large.net.xml
This will not only remove the edges but also try to adapt departure times.
Want to detect Is car take left turn or right turn on basis of azimuth,pitch and roll values calculated using sensors
Will i able to calculate using these values or need other parameters too?
Any Help will be appreciated :)
I have the following problem and I am a bit clueless how to tackle it as my programming skills are very elementary ( I am an engineer, so please dont bite my head off).
Problem
I have a point cloud, the picture above displaying one level off it. Every point is a centroid off a block (x =5, y=1, z=5) and is specefied by carteisian coordinates.
The centroids further have two values: one called "access" and one "product". If the product value is positive and pays for the access to the point I want to include it in my outcome. The red marker in the picture represents a possible starting point.
Starting Idea
As a start I am trying to set up an algorithm, that starts at the red marker, runs through the blocks left and right (along the x-axis), checks until where it would be feasible to access (so sum "product" > sum "access") and then goes to the next point (in y direction from marker) and does the same until the end of the level.
Final Goal
My final goal is that I can Flag points as accessed and the algorithm connects profitable "products" (so products that would pay for their access) on the shortest way to the access point (by setting blocks/points on the way to accessed).
I know this is a very open question and I apologize for that. I am just lacking a good starting point programming wise. I was thinking of knnsearch, but I am not sure if this is the right way to go as the blocks have different sizes and i technically want the nearest neighbour in every direction but also only one per direction.
Another idea I had was using shortestpath or creating a travel salesman problem out of it, but I am not sure how to properly implement it.
If you have any ideas or you could offer any help I would very much appreciate it. If any more information is needed I gladly provide it.