DIVA-DIA / DeepDIVA

⛔️ DEPRECATED <Python Framework for Reproducible Deep Learning Experiments>
https://diva-dia.github.io/DeepDIVAweb
GNU Lesser General Public License v3.0
32 stars 31 forks source link

Segmentation fault running setup_environment.sh when reinstalling (ubuntu) #4

Closed ajoino closed 5 years ago

ajoino commented 5 years ago

Hi.

I removed the DeepDIVA and miniconda3 folder to make a clean reinstall of DeepDiva, but everytime I run setup_environment.sh it get to line 42: echo 'source ~/.bash_functions' >> ~/.bashrc the terminal stops, prints 'segmentation fault' and crashes. If I then try to open a new terminal, it also crashes until I remove the source ~/.bash_functions from my .bashrc.

Initially, the segmentation fault showed up when I deteled everything within the >>>> initialized by conda block. I did this because I ran setup_environment.sh a second time (I did this really just to see what would happen). The result of running setup_enviroment.sh a second time was additional >>>> initialized by conda blocks in my .bashrc.

I am assuming that there is some .bash_whatever or some path variable that messes things up but I do not know where to start searching.

vinaychandranp commented 5 years ago

Can you attach your ~/.bashrc and ~/.bash_functions here?

ajoino commented 5 years ago

Of course

bash_functions.txt bashrc.txt This is the result of running setup_environment.sh a few times and removing the final source ~/bash_functions.sh to make bash not crash.

vinaychandranp commented 5 years ago

There ought to be a .bashrc-miniconda3.bak in your home folder. Can you check if that contains any lines added by Conda? If it does contain lines from Conda go to steps 1. Otherwise replace .bashrc with .bashrc-miniconda3.bak and go to step 2.

  1. remove the line source ~/.bash_functions from ~/.bashrc
  2. remove the ~/.bash_functions
  3. Log out of all open terminals and login again.

Hopefully this should fix the issue.

ajoino commented 5 years ago

Yes, my .bashrc-miniconda3.bak contained >>>> conda init and your solution worked, thank you!

If you don't mind, could you explain what was causing the error?

vinaychandranp commented 5 years ago

I think it was most likely an inconsistent state of environment variables as you guessed.