andlon / dynamecs Goto Github PK
View Code? Open in Web Editor NEWLicense: MIT License
License: MIT License
The snap documentation suggests to use a buffered reader when decompressing. However, the FrameEncoder docs suggest that buffering is not necessary for writing. So we should insert an intermediate BufReader
when restoring, but not when writing.
Need to install a custom panic handler that logs panics (and possibly flushes log writers if necessary)
We also need to store scenario config, maybe app settings etc. in the serialized checkpoint data.
Should also warn or even outright refuse to continue if there are mismatches.
Best idea so far: Refuse to run, but add CLI flag to override this behavior and run anyway (but log the mismatch with a warning).
Currently inserting several components for the same entity is very verbose:
universe.register_insert_component(obj, Name::from("box"));
universe.register_insert_component(obj, initial_state);
universe.register_insert_component(
obj,
MassDistribution::for_mesh_with_uniform_density(&mesh, density),
);
universe.register_insert_component(
obj,
ElasticSolidMaterial::for_mesh_with_uniform_parameters(&mesh, NeoHookeanMaterial, lame),
);
universe.register_insert_component(obj, FiniteElementDomain { mesh });
We could provide [register_]insert_components
functions that allow you to simplify the above to
universe.register_insert_components(obj, (
Name::from("box"),
initial_state,
MassDistribution::for_mesh_with_uniform_density(&mesh, density),
ElasticSolidMaterial::for_mesh_with_uniform_parameters(&mesh, NeoHookeanMaterial, lame),
FiniteElementDomain { mesh }
));
This is necessary so that Systems that use entities as references consistently work with the same entity no matter if the universe was initialized by the scenario initializer or restored from a checkpoint.
Currently we use type_name()
for identifying systems. However, this has several issues. For one, it's not necessarily unique for two different types T1, T2
. However, a potentially bigger problem is that the same type could technically produce different names when type_name()
is called from different locations in a program. Certainly there are no guarantees here.
It appears a better way might be to make a tag
available in the Component
trait, which can be used to produce storage tags. I'm thinking something like domain.ComponentName
. Then we can provide a derive(Component)
macro which allows you to specify domain
and derives ComponentName
from the type name.
Cool project!
There is missing README.md
and the crates.io / docs.rs doesn't have the link to this repository.
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.