ashryaagr / Fairness.jl

Julia Toolkit with fairness metrics and bias mitigation algorithms
https://ashryaagr.github.io/Fairness.jl/dev/
MIT License
31 stars 14 forks source link

@load_adult changes current directory #72

Closed gpucce closed 3 years ago

gpucce commented 3 years ago

Hi I don't know if this is a known issue, but using @load_adult appears to be changing the working directory.

julia> using Fairness

julia> pwd()
"/home/orefici/Repos/CItA_experiments/CItA_XAI"

julia> X, y = @load_adult;

julia> pwd()
"/home/orefici/.julia/packages/Fairness/1mEPa/data"

If the issue is real I'd be happy to try and help with a PR if you can point me to where I should look to fix it.

ashryaagr commented 3 years ago

Thanks a lot for pointing this out! I checked, and yes, the issue is real.

You can look at the definition for @load_adult macro here . The issue is probably because directory is changed in the ensure_download function here

Thanks again!