Skip to content

Cannot start simulation #4

@PhamAlexT

Description

@PhamAlexT

Environment

  • OS: Arch-based distribution
  • Java version: openjdk 19.0.2 2023-01-17
  • Gnuplot installed

Error message

Error: Could not find or load main class peersim.Simulator
Caused by: java.lang.ClassNotFoundException: peersim.Simulator

plot 
     ^
"./all.gpt" line 11: function to plot expected

Steps to reproduce the bug

  • Create a folder in the res/ directory as mentionned in the README.md (e.g results/)
  • Launch the follow command:
res/script/run.sh res/db/iris_setosa_versicolor_train.dat res/db/iris_setosa_versicolor_eval.dat 100 res/config/no_failure_applying_more_learners_voting10.txt res/results/

Expected behavior

The simulation starts and ends, outputting the results in the res/results/ folder.

Reasons

The variable cp in run.sh is incorrectly formatted due to the variable cpdelim being badly defined.

Fix used to solve this Issue

In run.sh, replace

export cpdelim=`java -help 2>&1 | grep -A 1 "classpath" | tail -n 1 | awk '{print $2}'`

with

export cpdelim=`java -help 2>&1 | grep -A 1 "class-path" | tail -n 1 | awk '{print $2}'`

Sincerely,

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions