- 博客(82)
- 收藏
- 关注
原创 CentOS 7上离线安装Claude Code
使用专门为旧版 glibc 编译的 Node.js 版本(由 unofficial-builds 提供)。脚本会依次完成:解压安装包 → 安装 Node.js → 配置 npm → 安装 Claude Code → 创建软链接 → 验证安装 → 配置模型连接。虽然 Claude Code 官方声明支持 CentOS 7+,但系统。: 使用自动化脚本安装时,安装过程会提示输入模型配置信息。如果直接安装官方 Node.js,会报错。
2026-05-07 18:07:43
1348
原创 vscode C/C++点击函数名/变量/文件名无法跳转
原因可能为clangd与Intelli Sense Engine冲突,并且把Intelli Sense Engine disable掉了导致,将。
2025-05-13 18:23:54
2126
原创 Mac安装YouCompleteMe
1. 安装bundle2. 下载源代码并配置vimrc打开~/.vimrc添加如下内容set rtp+=~/.vim/bundle/Vundle.vimcall vundle#begin()Plugin 'VundleVim/Vundle.vim'Plugin 'ycm-core/YouCompleteMe'call vundle#end()方法一直接在vim的normal模式中输入PluginInstall,安装完成会打开双编辑器并提示done,但是速度很慢很可能断开。方法二
2022-05-22 16:17:35
698
原创 安装oh-my-zsh及相关插件
Mac安装oh-my-zsh及相关插件1. 安装oh-my-zshsh -c "$(wget https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O -)"2. 安装高亮、提示、自动补全插件git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/z
2021-11-03 23:51:11
514
原创 Mac 使用C++11标准以及 bits/stdc++.h 万能头文件
Mac 使用C++11标准以及 bits/stdc++.h 万能头文件Mac平台下C++编译器为Clang无法使用C++11标准及bits/stdc++.h万能头文件,解决这个问题,需要:(1) 添加万能头文件在文件夹/Library/Developer/CommandLineTools/SDKs/MacOSX.sdk/usr/include/下新建文件文件夹bits,加入文件stdc++.h。bits/stdc+++.h内容:// C++ includes used for precompili
2021-08-08 14:50:31
1617
原创 tmux 使用总结
文章目录tmux 使用总结1. 常用命令2. 配置方法2.1. 打开鼠标滚屏模式2.2 选中复制配置文件tmux 使用总结1. 常用命令tmux:新建一个默认session并进入tmux new -s name:新建名字为name的session并进入tmux ls:查看所有的sessiontmux a -t name:连接进入名字为name的sessiontmux kill-session -t name:关闭名字为name的sessiontmux rename -t old_name
2021-06-21 00:44:06
1282
原创 cuda cudnn tensorflow pytorch安装
cuda cudnn tensorflow pytorch安装1. 查看显卡驱动版本及支持的cuda版本桌面右键NVIDIA控制面板->帮助->系统信息->组件:[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-DxLrrkDw-1606357029232)(…/%E5%9B%BE%E7%89%87%E6%96%87%E4%BB%B6/cuda%20cudnn%20tensorflow%20pytorch%E5%AE%89%E8%A3%85/image-2
2020-12-20 13:17:13
395
转载 pytorch中的view()和reshape()的区别
torch的view()与reshape()方法都可以用来重塑tensor的shape,区别就是使用的条件不一样。view()方法只适用于满足连续性条件的tensor,并且该操作不会开辟新的内存空间,只是产生了对原存储空间的一个新别称和引用,返回值是视图。而reshape()方法的返回值既可以是视图,也可以是副本,当满足连续性条件时返回view,否则返回副本[ 此时等价于先调用contiguous()方法在使用view() ]。因此当不确能否使用view时,可以使用reshape。如果只是想简单地重塑一个t
2020-12-20 13:11:35
1942
1
原创 numpy transpose和pytorch transpose, permute
numpy和pytorch维度转换将3x512x224 的数组第0维与第2维交换import torchimport numpy as npimage1 = np.random.randn(3, 512, 224)image2 = image1.transpose(1, 2, 0) # 参数指定的是维度最终的位置,这里是现在的0,1,2维为原来的1,2,0维,即 512x224x3print(f"image1: {image1.shape}\t image2: {image2.shape}"
2020-11-09 20:53:56
8336
原创 pytorch dataset图片显示
pytorch dataset图片显示plt参数可以是pytorch的tensor,也可以是numpy的array,但是维度必须是x*x*3;PIL.Image只能转化为x*x*3的numpy数组,不能转化为torch的tensor;torchvision的transform出来的是3*x*x的tensor,如果要画图需要转化为x*x*3用plt显示。import torchimport torchvisionimport argparseimport matplotlib.pyplot
2020-11-09 20:53:14
815
2
原创 python numpy.arry, pytorch.Tensor及原生list相互转换
文章目录python numpy.arry, pytorch.Tensor及原生list相互转换1 原生list转numpy list2 numpy.array 转原生list3 numpy.array转torch.Tensor4 torch.Tensor转numpy.array5 原生list转torch.Tensor6 torch.Tensor转原生listpython numpy.arry, pytorch.Tensor及原生list相互转换1 原生list转numpy listmy_list
2020-11-09 20:52:26
208
原创 当前的channels无法用conda安装某些包,查找适合的channel安装
当前的channels无法用conda安装某些包,查找适合的channel安装anaconda search -t conda visdomconda install -c https://conda.anaconda.org/conda-forge visdom
2020-09-05 15:04:07
1785
原创 安装了torchnet无法import
安装了torchnet无法importpip install git+https://github.com/pytorch/tnt.git@master
2020-09-05 15:03:15
648
1
原创 Linux conda安装pytorch速度慢
Linux conda安装pytorch速度慢1. 添加源conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/cloud/pytorch/conda config --add channels https://mirrors.sjtug.sjtu.edu.cn/anaconda/pkgs/main/conda config --add channels https://mirrors.sjtug.sjtu
2020-09-05 15:02:10
564
原创 Linux pip安装速度慢(超时报错),为pip换源
Linux pip安装速度慢(超时报错),为pip换源mkdir -p ~/.pip/vim pip.confpip.conf中内容如下:[global]index-url=http://mirrors.aliyun.com/pypi/simple/[install]trusted-host=mirrors.aliyun.com
2020-09-05 14:59:41
748
原创 linux安装conda并创建虚拟环境
linux安装conda并创建虚拟环境1. 下载安装脚本地址:https://repo.anaconda.com/archive/index.html选择:Anaconda3-2020.07-Linux-x86_64.sh2. 运行安装脚本执行bash [Anaconda3-2020.07-Linux-x86_64.sh;一直回车,知道出现问是否accept the license terms,敲yes;选择安装路径,默认即可;是否添加环境变量,敲yes(默认回车no);等待安装完成。3
2020-09-05 14:58:31
2405
1
原创 python numpy.arry, pytorch.Tensor及原生list相互转换
文章目录python numpy.arry, pytorch.Tensor及原生list相互转换1 原生list转numpy list2 numpy.array 转原生list3 numpy.array转torch.Tensor4 torch.Tensor转numpy.array5 原生list转torch.Tensor6 torch.Tensor转原生listpython numpy.arry, pytorch.Tensor及原生list相互转换1 原生list转numpy listmy_list
2020-09-05 14:57:18
484
原创 conda 安装GPU版tensorflow
conda 安装GPU版tensorflowconda create -n tensorflow python=3.6conda activate tensorflow conda install tensorflow-gpu
2020-09-05 14:55:10
568
原创 conda安装第三方包
以conda下安装jieba为例:运行命令conda install jieba 若无法正确安装,需要找到包对应的模块anaconda search -t conda jieba找到对应的版本[外链图片转存失败,源站可能有防盗链机制,建议将图片保存下来直接上传(img-tki84bJj-1592209676610)(https://raw.githubusercontent.com/laizhiping/blogPicture/master/Typora/image-202006
2020-06-15 16:29:20
1333
原创 Latex Matlab代码中文注释报错
latex在使用WinEdt10.2写带有中文注释的matlab公式时,会报错:使用方式为:\usepackage{listings} % 插入代码要用的包\begin{document}\begin{lstlisting}[language=Matlab] %读取训练数据并拼接 % batch_label 'training batch 1 of 5' % data 10000x3072 uint8 % labels 10000x1 uint8 load(
2020-06-01 22:34:28
1816
原创 sublime text3 配置conda环境
sublime text3 配置conda环境1. 安装conda插件ctrl + shift + p 后 输入 Package Control : Install Package,然后在弹出的输入框中输入conda,选择 conda然后回车安装,安装完成会跳出一个介绍界面2. 修改编译环境菜单栏选择 Tools -> Build System -> Conda3. 修改Conda环境配置菜单栏依次选择Preferences -> Package Settings ->
2020-05-12 10:23:07
2280
1
原创 latex编译报错:Font ntx-Regular- tlf-ot1r at 438 not found
在用TeXworks编译LaTeX时报如下错:Sorry, but miktex-makepk did not succeed.The log file hopefully contains the information to get MiKTeX going again: C:\Users\lzping\AppData\Local\MiKTeX\2.9\miktex\log...
2020-05-06 09:59:45
2244
转载 机器学习常用框架
转自 https://www.cnblogs.com/jiading/p/11750088.html 机器学习常用框架本文仅是我个人为了记录在学习机器学习过程中使用的各个软件工具,以便于有整体的理解先转载一个图,我觉得概括的很好:来源:https://blog.csdn.net/u014410989/article/details/89947128Pandas来源:http...
2020-04-28 10:46:59
881
原创 windows conda 报错:无法定位程序输入点OPENSSL_sk_new_reserve于动态链接库...\libssl-1_1-x64.dll
** 解决办法:**把Anaconda/DLLS 目录下的libssl-1_1-x64 dlls文件复制到Anaconda/Library/bin 目录下
2020-04-27 17:28:16
289
原创 ubuntu terminal光标消失
ubuntu terminal光标消失解决办法:echo -e "\033[?25h"若要隐藏光标,则用命令:echo -e "\033[?25l"
2020-04-16 14:16:31
3254
原创 ubuntu16.04 conda创建环境失败
直接用国外的源可能会报如下错:Solving environment: failedCondaHTTPError: HTTP 000 CONNECTION FAILED for url <https://repo.anaconda.com/pkgs/main/linux-64/repodata.json.bz2>Elapsed: -An HTTP error occurre...
2020-04-16 09:57:17
4330
1
原创 ubuntu python pip更新问题
You are using pip version 8.1.1, however version 20.0.2 is available.You should consider upgrading via the 'pip install --upgrade pip' command.解决办法:python -m pip install --upgrade pip
2020-04-15 17:26:05
217
转载 dijkstra算法和A*算法
Dijkstra算法 迪杰斯特拉(Dijkstra)算法是典型的最短路径的算法,由荷兰计算机科学家迪杰斯特拉于1959年提出,用来求得从起始点到其他所有点最短路径。该算法采用了贪心的思想,每次都查找与该点距离最近的点,也因为这样,它不能用来解决存在负权边的图。解决的问题可描述为:在无向图 G=(V,E) 中,假设每条边 E[i] 的长度为 w[i],找到由顶点vs到其...
2020-04-12 21:35:53
5909
原创 ubuntu16.04虚拟机安装ROS重启后无法进入图形界面解决办法 - The system is running in low-graphics mode
在虚拟机ubuntu16.04里安装完ROS kinetic,重启后出现如下问题:解决办法:点击确定, Ctrl+ALT+F1 进入控制台输入用户名和密码进入系统依次执行如下命令cd /etc/X11 sudo cp xorg.conf.failsafe xorg.conf sudo reboot 此时可以进入图形界面系统,但是无法全屏,需要更新一下:sud...
2020-04-07 17:10:37
1171
1
原创 ubuntu16.04安装ros kinetic
1. 配置软件和更新最好全部选上,注意源不要换(换了国内源可能安装会出问题)全勾选,不勾选会有问题!Ubuntu软件和更新勾选完毕之后点击关闭,点击之后可能有点慢,耐心等待。2. 设置sources.listsudo sh -c 'echo "deb http://packages.ros.org/ros/ubuntu $(lsb_release -sc) main" >...
2020-04-07 13:49:40
337
原创 python sort和sorted
转自 https://www.jianshu.com/p/419a8732ac62一、函数sort()sort() :仅对list对象进行排序,会改变list自身的顺序,没有返回值,即原地排序;list.sort(key=None, reverse=False)key :设置排序方法,或指定list中用于排序的元素;reverse :升降序排列,默认为升序排列;一维...
2020-03-30 20:46:00
197
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人
RSS订阅