Skip to content

Commit

Permalink
Test simulation parallel refactored.
Browse files Browse the repository at this point in the history
  • Loading branch information
Smoren committed May 13, 2024
1 parent 32957bc commit ec66c73
Showing 1 changed file with 14 additions and 3 deletions.
17 changes: 14 additions & 3 deletions src/scripts/actions/test-simulation-parallel.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,8 +10,6 @@ export const simulationTask = async (
console.log(`-> task ${id} started`);
const ts = Date.now();

console.log('initial', worldConfig);

worldConfig.TEMPERATURE_FUNCTION = () => 1;

const dirName = __dirname.replace('/node_modules/multiprocess-pool/dist', '/src');
Expand Down Expand Up @@ -50,9 +48,22 @@ export const actionTestSimulationParallel = async (...args: string[]) => {

const worldConfig = createBaseWorldConfig();
const typesConfig = createBaseTypesConfig();

const stepsCount = 300;
const atomsCount = 500;
const minPosition = [0, 0];
const maxPosition = [1000, 1000];

worldConfig.CONFIG_2D.INITIAL = {
ATOMS_COUNT: atomsCount,
MIN_POSITION: minPosition,
MAX_POSITION: maxPosition,
};

worldConfig.CONFIG_2D.INITIAL.ATOMS_COUNT = 1000;
worldConfig.CONFIG_2D.BOUNDS = {
MIN_POSITION: minPosition,
MAX_POSITION: maxPosition,
};

const inputs = [
[1, worldConfig, typesConfig, stepsCount],
Expand Down

0 comments on commit ec66c73

Please sign in to comment.