Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Ids are not reset between runs #18

Open
jgpavez opened this issue Nov 2, 2018 · 4 comments
Open

Ids are not reset between runs #18

jgpavez opened this issue Nov 2, 2018 · 4 comments

Comments

@jgpavez
Copy link
Collaborator

jgpavez commented Nov 2, 2018

When running the code twice as:

include("call_experiment.jl")
args =["4", "1000", "f1", "1234", "2", "2","summary"]
experiment(args)
experiment(args)

I get the following error

ERROR: BoundsError: attempt to access 4×1000 Array{Float64,2} at index [5, Base.Slice(Base.OneTo(1000))]
Stacktrace:
 [1] throw_boundserror(::Array{Float64,2}, ::Tuple{Int64,Base.Slice{Base.OneTo{Int64}}}) at ./abstractarray.jl:434
 [2] checkbounds at ./abstractarray.jl:362 [inlined]
 [3] macro expansion at ./multidimensional.jl:494 [inlined]
 [4] _getindex(::IndexLinear, ::Array{Float64,2}, ::Int64, ::Base.Slice{Base.OneTo{Int64}}) at ./multidimensional.jl:491
 [5] final_output(::Array{Float64,2}, ::Int64, ::Array{Any,1}, ::Array{Any,1}, ::Int64) at /DistributedMachineLearningThesis/src/master_summary.jl:163
 [6] run_experiments(::Int64, ::Int64, ::String, ::Int64, ::Int64, ::String) at /DistributedMachineLearningThesis/src/master_summary.jl:395
 [7] execute_experiment(::Array{String,1}) at /DistributedMachineLearningThesis/src/master_summary.jl:474
 [8] experiment(::Array{String,1}, ::Vararg{Array{String,1},N} where N) at /DistributedMachineLearningThesis/src/call_experiment.jl:21

It is because ids are not reset between the runs. So in the second experiment(args) ids are 5,6,7,8 instead of 1,2,3,4. This is incompatible with how the code works.

@lagefreitas
Copy link
Collaborator

@NaelsonDouglas could you try to fix this please?

@lagefreitas
Copy link
Collaborator

BTW, @jgpavez this bug seems weird because, as long as I remember, @NaelsonDouglas coded this part so we wouldn't add worker for repeating the experiments in order to decrease the remove/add worker overhead. Would might be possible that you are calling the code in a wrong way?

What do you think @NaelsonDouglas ?

@NaelsonDouglas
Copy link
Owner

I wasn't able to reproduce the bug.

I executed this snippet of code (without closing the Julia terminal) and didn't get the error.
include("call_experiment.jl") args =["4", "1000", "f1", "1234", "2", "2","summary"] experiment(args) experiment(args)

There was another error preventing the cointainers.csv of being populated. It was caused because g wasn't being initialized, but I solved it in this commit

@lagefreitas
Copy link
Collaborator

thanks @NaelsonDouglas. @jgpavez , could you try again to run the experiments?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants