Execute the following so that the python command is redirected properly.
python
eval "$(pyenv init -)"