Mac M1 安裝使用 streamlit


查閱網上或者官網,大致安裝流程是->pip3 install streamlit     ->streamlit hello 但是這個操作在Ubuntu 或者是intel芯片的mac上是有效的,當在Mac M1上安裝使用時就會出現問題,當執行完第一條命令->pip3 install streamlit之后,第二條命令 ->streamlit hello會報錯zsh: command not found streamlit. 通過參考其他模塊安裝流程找到了答案:

應該在執行完第二條命令之后繼續執行 ->vim ~/.zshrc     

然后添加->pip3 install streamlit 安裝過程顯示的路徑。 我的是     WARNING: The script streamlit is installed in '/Users/(MYNAME)/Library/Python/3.8/bin' which is not on PATH.

因此你需要將這個路徑添加到.zshrc文件中。export PATH=/Users/(MYNAME)/Library/Python/3.8/bin:$PATH      

最后記得執行一下->source ~/.zshrc

 

 

ok  that‘s all.

 

后續我會再發一些steamlit使用上的有趣的事。

快要到元旦了,祝大家元旦快樂。


免責聲明!

本站轉載的文章為個人學習借鑒使用,本站對版權不負任何法律責任。如果侵犯了您的隱私權益,請聯系本站郵箱yoyou2525@163.com刪除。



 
粵ICP備18138465號   © 2018-2025 CODEPRJ.COM