- 博客(42)
- 收藏
- 关注
原创 安装pytorch-gpu
只有pytorch-cpu,无法使用如下命令安装pytorch-gpu。根据cuda版本使用pip3安装torch。查看cuda版本,比如11.6。
2023-12-03 16:52:19
123
原创 vscode Git: Host key verification failed.
原因:~/.ssh/known_hosts中没有github.com。
2023-09-13 13:52:02
226
原创 vscode ssh waitting for forward port to be ready
问题:vscode 右下角出现 Waiting for port forwarding to be ready。原因:可能是ssh插件版本问题。解决:重新安装之前的版本。
2023-09-11 14:40:01
1035
原创 ZeroTier客户端连接服务器
官方文档 https://docs.zerotier.com/getting-started/getting-started。注: 若路由器无法获取IPv4的物理IP,可尝试打开路由器IPv6功能。ZeroTier客户端连接服务器。
2023-09-08 18:51:21
826
原创 zerotier requesting configuration
Q:zerotir无法获取physical ip。A:路由器管理页面开启ipv6。
2023-08-13 10:44:00
1732
原创 pytorch GPU inputs 超出边界
RuntimeError: CUDA error: device-side assert triggered CUDA kernelerrors might be asynchronously reported at some other API call,so thestacktrace below might be incorrect. For debugging consider passingCUDA_LAUNCH_BLOCKING=1.注意输入范围:input_ids (torch..
2022-05-28 09:47:57
511
原创 vscode 只显示一个标签页
Ctrl Shift Psetting json“workbench.editor.showTabs”: true
2022-05-27 15:30:35
438
转载 Macos Notification Center(通知中心)应用残留问题
https://www.v2ex.com/t/626418通知中心选中项目cmd + backspace
2022-05-14 11:18:49
388
原创 latex使用xeCJK字体报错
网上一堆答案,但很多是折腾又麻烦,找不到称心如意的。但我发现,有时,先不去管报错,等内容差不多写好了再统一调格式。有一些报错的内容会随着内容的丰富,不再是错误,可能转为警告,但这不影响编译。...
2022-05-14 11:09:12
1352
原创 jupyter argparse 交互式 传参
(已解决)Jupyter Notebook使用argparse报错:An exception has occurred, use %tb to see the full traceback.parser.parse_args(args=[]) # 默认参数parser.parse_args(args=["--debug", "--gpu=0", "--epoch=1"]) # 传入参数parser = argparse.ArgumentParser()parser.add_argument('-
2022-05-04 14:57:55
1419
原创 tensor不在同一设备上:创建tensor后就马上.to(device)
创建tensor就要.to(device)labels = torch.zeros(logits.shape[0],logits.shape[1]).to(device).scatter_(dim=1,index=labels,src=torch.ones(labels.shape[0],labels.shape[1]).to(device))
2022-04-03 22:52:16
1070
原创 vscode push code to github
当发现vscode怎么推都报错,说授权问题时,可能是vscode版本问题,更新或回退可能是一个好主意。
2022-03-09 15:53:48
258
原创 使用 biblatex 管理书目
biblatex包的最小工作示例如下所示:\documentclass{article}\usepackage[utf8]{inputenc}\usepackage[english]{babel}\usepackage{biblatex}\addbibresource{sample.bib}\begin{document}Let's cite! The Einstein's journal paper \cite{einstein} and the Dirac's book \cite{
2022-03-05 16:21:22
201
原创 latex本地编译llncs2e参考文献报错
原答案:BibLaTeX本地编译Empty Bibliography Citation Undefined错误的解决方法问题描述:在 Overleaf 上使用这些语句即可成功生成 Reference,然而本地编译却编译不出,而采用 pdflatex -> bibtex -> pdflatex2 或 xelatex -> bibtex -> xelatex2 的 recipe 会报错,显示 Empty Bibliography、Citation Undefined。参考Late
2022-03-05 15:14:53
273
原创 latex插入pdf
开头加 \usepackage{pdfpages}使用中 \includepdf[pages=-]{插入的文件.pdf}http://blog.sina.com.cn/s/blog_5dc0a51401013lu7.html
2022-01-23 23:25:03
10097
原创 使用Tencent Lemon卸载顽固软件
腾讯mac管家Tencent Lemon卸载软件直接卸载即可开机启动取消开机启动,可能再其他类中(可选)查看并手动删除该启动文件
2021-12-31 15:07:26
1188
原创 sns解决显示不全不清晰及保存不全问题
import matplotlib.pyplot as pltimport pandas as pdimport seaborn as snsplt.figure(figsize=(15, 10))sns.heatmap(con, cmap='Reds', annot=True, fmt='d' ).get_figure().savefig("temp.png",dpi=500,bbox_inches
2021-12-28 13:33:34
2685
原创 vscode上传代码到github提示验证错误
在.git中修改url为github项目仓库的ssh连接,如下:url = git@github.com:用户名/项目名.git
2021-11-27 22:44:15
735
原创 tensorflow无法使用GPU
卸载tensorflowconda uninstall tensorflow安装tensorflow-gpuconda install tensorflow-gpu测试,结果非0即可import tensorflow as tfprint("Num GPUs Available: ", len(tf.config.list_physical_devices('GPU')))`若不行,则重建conda环境# 创建环境conda create -n 新环境名称# 进入环境conda
2021-11-17 13:58:16
1041
原创 Paragon NTFS for Mac 解决macos无法读写U盘问题
下载https://www.ntfsformac.cn/xiazai.html
2021-11-08 10:35:48
461
原创 jupyter An exception has occurred, use %tb to see the full traceback.
https://www.codenong.com/cs110438223/change:args = parser.parse_args()to:args = parser.parse_args(args=[])
2021-11-03 14:18:58
536
原创 vscode+Latex Ubuntu 简洁配置
Latex下载LatexInstalling TeX Live over the Internet - TeX Users Groupcd 文件路径perl install-tl(会安装半小时左右)安完后vim ~/.bashrc在文档底部添加并保存export PATH=/usr/local/texlive/2021/bin/x86_64-linux:$PATH
2021-10-30 12:10:22
274
原创 更改python工作目录 讲脚本参数转入py文件中进行debug
# change workpathimport osos.chdir('D:/code')
2021-10-16 14:20:45
119
原创 Mac安装lightgbm报错image not found
不好使:pip install lightgbm说:image not found1.安装 cmake, gccbrew install cmakebrew install gcc2.安装 LightGBMgit clone --recursive https://github.com/Microsoft/LightGBM ; cd LightGBMexport CXX=g+±7 C...
2020-03-22 04:03:20
232
原创 解决tensorflow2.0无法使用1.0算法问题
在tf后面+.compat.v1比如:原为tf.Session() as sess:tf.global_variables_initializer()改为tf.compat.v1.Session() as sess:tf.compat.v1.global_variables_initializer()
2020-03-18 18:53:19
1890
原创 MacOs 删除无用虚拟声卡
Finder→shift+command+G→输入/Library/Audio/Plug-Ins/HAL/driver.png删除Apowersoft Audio Device.driver文件系统重启即可
2020-02-22 23:34:56
8912
3
原创 MacOs卸载Adobe后还有残留进程的解决方法
https://helpx.adobe.com/cn/creative-cloud/kb/cc-cleaner-tool-installation-problems.htmlAdobeCreativeCloudCleanerTool.dmg
2020-02-21 19:15:48
4892
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人