cityscope / cs_simulation_gama Goto Github PK
View Code? Open in Web Editor NEWAgent Based Simulation platform for CityScope
License: GNU General Public License v3.0
Agent Based Simulation platform for CityScope
License: GNU General Public License v3.0
change it from skeleomorphism to flat and give a generic way to set size and pos
current_concentration is not yet updated.
I disable the rendering of it for now until it''s not working
As discussed with @agrignard and @sannailtanen, we need to create an ABM for the campus with a lot of the same functionality as CityScope_main.gaml. However, some functionality will need to be modified/extended. For example:
What is the best way to do extend an existing model? Should we import the entire model CityScope_main.gaml? If we do this, can we then overwrite certain parameters and methods of the model?
Or can we import specific parts of CityScope_main.gaml? eg. can we import all the species and experiments but write new code for the global parameters and reflexes?
Right now all trips take place between buildings on campus and the number of agents is arbitrary. A number of changes should be made to improve the realism of the model.
Point 1 may take some time but we can proceed with points 2 to 4 with some assumed numbers for now.
Since Volpe is only 1Km by 1Km, commuting by car is not that popular.
@agrignard Can we have a link to Ronan's Mocho data, and use that to feet the zombies?
If not, can we have all the Boston area as a playground?
scale <- scale_string[rnd(2)];
it should come form the GIS file
In order to make the model useful for scenario evaluation we must be able to experiment with different scenarios of parking and housing provision. When additional housing is added, it should have the effect of converting 'external trips' which have a high likelihood of driving to to 'internal trips' which have a lower likelihood of driving.
There are several ways this interactivity can be added:
Make assumptions about commuting behaviors: specifically, how many people would live and work in the district and those who commute in each day from outside of the district. Assumptions will also be made about behaviors with respect to people who enter and leave the district for other no-work activities (recreation, shopping, etc.)
The code of the model can gain a lot in genericity by defining an activity species.
Right now the GAMA ABM Volpe model is plugged to the GH scanning which is not sending a 2.1 version of cityIO and I don't knwo wiehter or not @popabczhang will have time to update it. In any case in order to have a generic model it would be great to have a 2.1 scanner that would send a 2.1 format and then having the 2.1 reader in the GAMA model in parallele
Other issue is that at the .csv, the "bus_distance" is = 0.0 all the time and in all the simulations
A cool way to visualize people activity could be to do that
http://flowingdata.com/2015/12/15/a-day-in-the-life-of-americans/
Define the types of mobility modes for the project, including the vehicle characteristics of both existing and new modes (# passengers, speed, autonomous vs. conventional, etc.) and how each mode may be integrated with existing and proposed public transit. Define assumptions about the mobility use patterns of people (agents) that will be used to establish the origin/destination pairs for agent behaviors.
It looks like people are not (anymore) using the street
I've created some dynamic pie charts for the Aalto simulation. However, as shown in the image below, the labels are generated automatically in a way that is hard to read. How can we customise the content of the labels the width of the label boxes (so that the text doesn't get split across multiple lines).
right now when cityIO is no sending density data (which actually happens many times) the simulation is crashing because it's trying to access an empty array.
Find a way to have at least a simulation that does not crash
Define the profiles of people, numbers, and origin and destination points as determined by places of living, work, and other activities - including people who live in the district and those who commute. Profiles of people living in each type of residential building, working in each type of commercial building, and attracted to 3rd places (students, young professionals, families, mid- career workers, senior executives, etc.). This information will be used to establish the behaviors of each agent type: where they live, where they work, and the "3rd places" that they visit.
Clean the code !
I understand that we want to differentiate the aspect (color,witdth, speed) form the characteristic but then it complexifies the description of the model. I would be in favor to merge the two file in a big file that is about Mode
What do you think?
At the CSV file we can see that something is wrong with the "Bikes". It is increasing in a linear growth
<img src=https://www.dropbox.com/s/ykc5vckqtgb1sq0/Bike.png?dl=0 />
The model uses several variables to define the current date and time instead of using the date type with the staring_date and current_date built-in variables,.
In dev run game_it_v1.0.gaml pie charts doesn't work properly (index ouf of bounds)
It used to work? Something related to GAMA 1.7 vs GAMA 1.8?
Temporaly remove to make it cleaner in a separate file and using the new Gama Plot feature
5a42a92
hourly, daily
I need to remove the entropy code temporally. Here is the commit where it has been remove.
I am working on a better architecture where typically that kind of stuff should be in a separate file dedicated to the analysis of the simulation.
Refine the initial urban plan to delineate the level of detail required for the agent–based simulation: uses of each building (types of residential, types of office, 3rd places (restaurants, shops, etc.) schools, cultural facilities, types of parks, etc.
Right now people that lives in a specific building doesn't go back home in the same buildng after one hour.
Define a generic way to describe the data required to construct an agent-based model, including GIS description of the proposed urban plan (buildings and roadways), total floor area of each building, estimated occupancy, building heights, transportation data, etc. The quality of the data will impact on the accuracy of the agent-based model.
This model was developped before cityIO grid format and the settings about the city are hardcoded directly in the model. It should be read ideally from cityIO and at least from a local file using the same format as cityIO
// Variables used to initialize the table's grid.
float angle <- -9.74;
point center <- {1007, 632};
float brickSize <- 21.3;
@doorleyr In the same way as what we did we CityScope_main.gaml creating an aalto extension it wouldn't be too hard to make the same for Game_IT.gaml.
Now the fact that the road doesn't go to the bulidng takes lots of time in computation (for the agent to compute the shortest building)
One optimization is to link every building to the road network by generating the road
The Agents are in a loop. Can we introduce some "realistic" Françoize Aléatoire?:
<img src=https://www.dropbox.com/s/2x39pkr2u6gwguo/Clone.png?dl=0 />
Find a way to refactor this piece of code and put it in the experiment
if(cityScopeCity= "volpe"){
angle <- -9.74;
center <-{3305,2075};
brickSize <- 70.0;
coeffPop<-1.0;
coeffSize<-1;
}
A soon as this is ready CityScope/CS_CityIO#25
Start the new parser in GAMA
save(json_file("https://cityio.media.mit.edu/api/table/update/grasbrook/cityIO_Gama_Hamburg", c));
Doesnt work anymore
distance_travelled per mode per people
average time spend per mode
price spent per mode
Right now if we want to push a list as a json file in cityIO from GAMA the list will be automatically stored as a map which results to a slightly different string that the one expecting
see here:
https://cityio.media.mit.edu/api/table/grasbrook/cityIO_Gama_Hamburg
This is a valid restriction from GAMA because:
JSON stands for JavaScript Object Notation, so a JSON file should be the description of a Javascript Object, which is a map, not an array.
However in a recent commit (gama-platform/gama@23f1a7e), the GamaJsonFile implementation has been updated (adapting to GAMA data structures a more recent version of the json-simple library to avoid too much serializations/deserializations), which, when asking to save a map with only one entry with "contents" as key, will serialize and save the corresponding value instead. Reading this kind of JSON list will, as it was doing before, produce a single-entry map.
So this should be fixed soon without the "contents" filed
Develop alternate scenarios to be modelled. Scenarios may relate to modal mix and assumptions about adoption rates of autonomous vehicles. Develop visualizations of modelled scenarios. These visualizations will be presented in video format.
Currently all person agents pick their housing from the full list of vacant houses. However, students and staff should have different choice sets and/or preferences. To implement this, we need to know which person types prefer which housing types.
The residential buildings in the Buildings and Campus_Buildings shape files have a Scale attribute with values S, M or L. @sannailtanen What kinds of housing do each of these categories represent and how were they determined?
We have 2 types of people seeking housing: students and staff? Which of the housing types above are student housing and which are for staff/others?
The Aalto model should have some charts (eg. time series plot, histogram, bar chart etc.) to show the most important indicators in real-time. Some examples of important indicators include:
https://github.com/CityScope/CS_Simulation_GAMA/blob/master/CS_CityScope_GAMA/models/Game_IT.gaml
@Babakfifoo I just ran the aalto model and it becomes very slow after few iterations do you have an idea why? With thousands of agents we shouldn't have such a slow model.
Please, add a few notes about how to use qgis for make a map for the gama simulation project.
the simulation code look for building of type ("R") at start for put agent in it so they can start to move, shouldnt i use a filter for select them on map and assign them this attribut in qgis?
ps: and for volpe, from where do you got these csv? :)
Working: circle
Moving: empty circle
Eating: Half full
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.