curds01 / mengeutils Goto Github PK
View Code? Open in Web Editor NEWCollection of utilities for working with Menge configuration and output files
Collection of utilities for working with Menge configuration and output files
Trying to delete agents in the AgentContext
causes the application to crash. Upon fixing it, make sure to update the documentation in roadmap_builder.md
.
Hi! I'm using menge and your tools for my degree's final project. I've been searching for scb file format, but nothing found. Is there a standard of something like this of scb files?
I want to playback a menge scene with roadmapBuilder but the agent radius is not shown correctly. Menge don't seems to export this data in the scb file. I want to add this feature in menge and then add it in roadmapBuilder, and I was wondering if there is a correct way to do this.
Thank you. Best regards.
When attempting to smooth a vector field, it is common to crash (see below for example crash stack trace).
The algorithm works by "clipping" region to be smoothed. It then creates a smoothed version of that region and then blends it into the actual region based on gaussian weights. The problem arises in smoothFieldRegion
. Specifically, the comment here. Specifically, it uses a gaussian kernel to create a smoothed value for each cell. This encompasses data outside the region. If that extent goes beyond the actual extent of the vector field, bad things happen. The todo addresses (rather loosely) these bad things and admits that no particular design has been tackled. One of the symptoms of these "bad things", is that the smoothed region doesn't come back with the right size. No matter what other bad things happen, the smoothed region should be of the size requested.
There are several ways to handle boundary conditions:
Traceback (most recent call last):
File "roadmapBuilder.py", line 436, in <module>
main()
File "roadmapBuilder.py", line 406, in main
result = handleMouse( event, context, view, graph, obstacles, agents, field )
File "roadmapBuilder.py", line 95, in handleMouse
result = context.handleMouse( event, view )
File "P:\e_drive\work\projects\objreader\RoadContext.py", line 123, in handleMouse
return self.activeContext.handleMouse( event, view )
File "P:\e_drive\work\projects\objreader\RoadContext.py", line 1324, in handleMouse
result.combine( self.activeContext.handleMouse( event, view ) )
File "P:\e_drive\work\projects\objreader\RoadContext.py", line 1432, in handleMouse
self.doWork( (dX, dY ) )
File "P:\e_drive\work\projects\objreader\RoadContext.py", line 1534, in doWork
smoothStroke( self.field, self.smoothStrength, self.kernelSize, ( self.downX, self.downY ), self.brushPos, self.brushSize )
File "P:\e_drive\work\projects\objreader\fieldTools.py", line 227, in smoothStroke
smoothFromDistance( field, strength, kernelSize, minima, maxima, distances, radius )
File "P:\e_drive\work\projects\objreader\fieldTools.py", line 260, in smoothFromDistance
newVectors = weights * smoothed + ( 1 - weights ) * region
ValueError: operands could not be broadcast together with shapes (12,11,1) (11,11,2)
Given an scb file (version 2.1) from the 4square demo, I can load the SCB via:
python roadmapBuilder.py -b ..\menge_fork\examples\core\4square\4squareS.xml -s ..\menge_fork\Exe\4square.scb
I can advance the time step as expected with the right-arrow key. But trying to back up a frame produces the error:
Error with keyboard event
The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
Using the same SCB, if the frame is advanced to the end (by using the modifiers to move at a higher rate), trying to step back causes a crash with the message:
Error with keyboard event
string is smaller than requested size
NOTE: This error does not seem to occur when one approaches the end with a single-frame step.
Hi @curds01 , I got your link from the Menge crowd simulator repo, can you provide me the documentation of repo as well (email: [email protected]) ? in order to use Menge and also can you help me out to create my own simulation using menge and read the trajectories of these simulations?
The mechanism for building a roadmap graph is not consistent with all the other tools. It needs to
be wrapped into a context for consistency. Upon fixing it, make sure to update the documentation in roadmap_builder.md.
Hi, thanks for sharing your menge utilities with us.
I've been using ObjSlice to Slice the .obj file to create obstacles, it works really well on simple objects such as cube or tetrahedrold. But when I apply it to some complex obj file, I ran into some errors.
For example, for this obj file https://github.com/xiangyuanhang/files/blob/master/kitchen3_fisher.obj, if I set the parameter as follows:ObjSlice.py -i objfiles/kitchen3_fisher.obj -p 0 0 1 -0.5 -o 0421.xml
. It reports this error:
ZeroDivisionError: float division by zero
And then if I set the parameter like this: ObjSlice.py -i objfiles/kitchen4_fisher.obj -p 0 0 1 -0.5 --segment -o 0421.xml
, which means I want each segement to be a unique obstacle instead of connecting them as polygons.
But however, when I check the xml file it created, there are lots of points that have been counted more than once.
So I am wondering how does the program selects the point. And is it possible that this program could connect the related points and create a coresponding closed polygons? (For the moment, it reports the ZeroDivisionError: float division by zero
error)
Thanks in advance!
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.