Mac下安装anaconda,创建scanpy环境

官网下载anaconda

一般软件的安装方式
ref
成功后打开-打开terminal终端——可以直接进入base
(后面不从这个软件界面,直接终端activate 也有报错)
在这里插入图片描述

关于CLTcode 不可用

  • CLTcode 匹配

Mac系统:本来是Mac os monterey 12.5
在安装过程中 更新了一下,成了12.6

这个不知道怎么匹配 CLT
ref
https://blog.youkuaiyun.com/HONGcheng930728/article/details/116245646

Mac brew Error: Your CLT does not support macOS 11.2

但是按照此方法并没有解决12.5或者12.6的系统匹配问题
换了 Xcode 也还是没有解决

试用过三个版本的Command_Line_Tools_for_Xcode_12.5.1.dmg
Command_Line_Tools_for_Xcode_14.dmg
下载地址:
https://developer.apple.com/download/more/
还是报错

安装scanpy

umap 版本和scanpy的版本不一致

ref. https://www.jianshu.com/p/82c7b978908c
在这里插入图片描述

解决:
安装Python=3.8

wget 不存在

MacOS 报错提示 zsh: command not found: wget

mac wget: command not found

找到说要 brew install wget

brew install libunistring
brew install openssl@1.1
brew install wget

前两个命令需要先安装homebrew,当提示未找到 brew 时,按以下方式操作

进入 homebrew官网

ref. https://blog.youkuaiyun.com/qq_44664231/article/details/126062112

然后遇到了各种错误

Your CLT does not support macOS 11.5 - 知乎

Mac下安装homebrew(解决error: RPC failed; curl 56 LibreSSL SSL_read: SSL_ERROR_SYSCALL)

安装brew报错:error: RPC failed; curl 56 LibreSSL SSL_read: SSL_ERROR_SYSCALL, errno 54
这个没有解决

git config --globle error: unknown option `globle’ -

ping github.com -

0 packets received, 100.0% packet loss

更改hosts 也是不行的
mac下 ping github超时问题
这个没用

RPC failed; curl 56 LibreSSL SSL_read: error:02FFF036:system library:func(4095):Connection reset by peer, errno 54

其实参考了很多,都没有解决问题!!!
反正对我没有用

我也改了ip.

最终终极大法!改镜像!!!

MacOS系统使用 Homebrew 官方地址时,报错:

Mac:/bin/bash -c “$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install.sh)”

curl: (35) LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection to raw.githubusercontent.com:443
解决办法:
使用国内源

/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh)"

该地址提供多个国内源地址,选择一个安装即可,我选的5 阿里云
在这里插入图片描述
这个基本解决了问题 ,唯一的有一个报错

HomeBrew : Command failed with exit 128: git 异常处理

应该是git的识别问题

ref

在这里插入图片描述
执行上图红线中的 git 命令,就可以了。 最后用 brew -v 看下结果,如下图所示。

在这里插入图片描述
至此
可以
完成wget
可以运行!wget http://cf.10xgenomics.com/samples/cell-exp/1.1.0/pbmc3k/pbmc3k_filtered_gene_bc_matrices.tar.gz -O data/pbmc3k_filtered_gene_bc_matrices.tar.gz

tutorial: pbmc3k 官网教程报错

按照官网的教程走

# !mkdir data
# !wget http://cf.10xgenomics.com/samples/cell-exp/1.1.0/pbmc3k/pbmc3k_filtered_gene_bc_matrices.tar.gz -O data/pbmc3k_filtered_gene_bc_matrices.tar.gz
# !cd data; tar -xzf pbmc3k_filtered_gene_bc_matrices.tar.gz
# !mkdir write

一直到后面报错
##KeyError: ‘base’ when running tl.rank_genes_groups

ref. github 上有issue

解决方法
or now, I use the line adata.uns['log1p']["base"] = None
every time after reading a h5ad file.

此方法还能解决同样的报错
sc.pp.highly_variable_genes(Adult,batch_key=‘batch’)

PS D:\毕设\Spacia\DB> pip install cellphonedb -i https://pypi.tuna.tsinghua.edu.cn/simple Looking in indexes: https://pypi.tuna.tsinghua.edu.cn/simple Requirement already satisfied: cellphonedb in d:\conda\anaconda\lib\site-packages (5.0.1) Requirement already satisfied: anndata>=0.8 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (0.11.3) Requirement already satisfied: geosketch>=1.2 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (1.3) Requirement already satisfied: ktplotspy>=0.1.4 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (0.3.0) Requirement already satisfied: numpy>=1.21.6 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (1.26.4) Requirement already satisfied: numpy-groupies>=0.9.15 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (0.11.2) Requirement already satisfied: pandas>=1.5.0 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (2.2.2) Requirement already satisfied: pytest>=7.2.0 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (7.4.4) Requirement already satisfied: requests>=2.25.0 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (2.32.3) Requirement already satisfied: scanpy>=1.9.1 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (1.11.0) Requirement already satisfied: scikit-learn>=1.2.2 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (1.5.1) Requirement already satisfied: tqdm<5.0,>=4.3 in d:\conda\anaconda\lib\site-packages (from cellphonedb) (4.66.5) Requirement already satisfied: array-api-compat!=1.5,>1.4 in d:\conda\anaconda\lib\site-packages (from anndata>=0.8->cellphonedb) (1.11.1) Requirement already satisfied: h5py>=3.7 in d:\conda\anaconda\lib\site-packages (from anndata>=0.8->cellphonedb) (3.11.0) Requirement already satisfied: natsort in d:\conda\anaconda\lib\site-packages (from anndata>=0.8->cellphonedb) (8.4.0) Requirement already satisfied: packaging>=20.0 in d:\conda\anaconda\lib\site-packages (from anndata>=0.8->cellphonedb) (24.1) Requirem
03-08
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值