Hey folks,
I’m trying to activate fastai (or pytorch) using “mamba” from my M2 Mac terminal. However, I’m getting an error:
Run 'mamba init' to be able to run mamba activate/deactivate
and start a new shell session. Or use conda to activate/deactivate
I’m new to handling environments and shell. Can someone pls help me out ?
“mamba install fastai” command worked successfully.
“conda activate fastai” worked successfully as well.
But mamba activate fastai is giving the above error.
I ran mamba init and started a new terminal session, but it didn’t work. Again the same error.
Can someone pls help me out. Thanks!
Hey , thanks for reply. What should I copy from bash to zsch ?
These are the contents of my ~/zshrc file:
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$('/Users/kashmkj/miniforge3/bin/conda' 'shell.zsh' 'hook' 2> /dev/null)"
if [ $? -eq 0 ]; then
eval "$__conda_setup"
else
if [ -f "/Users/kashmkj/miniforge3/etc/profile.d/conda.sh" ]; then
. "/Users/kashmkj/miniforge3/etc/profile.d/conda.sh"
else
export PATH="/Users/kashmkj/miniforge3/bin:$PATH"
fi
fi
unset __conda_setup
# <<< conda initialize <<<
These are the contents of my ~/bash_profile file:
# >>> conda initialize >>>
# !! Contents within this block are managed by 'conda init' !!
__conda_setup="$('/Users/kashmkj/miniforge3/bin/conda' 'shell.bash' 'hook' 2> /dev/null)"
if [ $? -eq 0 ]; then
eval "$__conda_setup"
else
if [ -f "/Users/kashmkj/miniforge3/etc/profile.d/conda.sh" ]; then
. "/Users/kashmkj/miniforge3/etc/profile.d/conda.sh"
else
export PATH="/Users/kashmkj/miniforge3/bin:$PATH"
fi
fi
unset __conda_setup
if [ -f "/Users/kashmkj/miniforge3/etc/profile.d/mamba.sh" ]; then
. "/Users/kashmkj/miniforge3/etc/profile.d/mamba.sh"
fi
# <<< conda initialize <<<
Hey thanks for the reply. Yeah, after a few nitty-gritty changes, i was able to activate using micromamba. But now, alone “mamba/conda” command doesn’t work…lol. I’m only able to use micromamba. Need to check what went wrong in my installation.