- 博客(9)
- 收藏
- 关注
原创 【KeyError: ‘unexpected key “module.*****“】【KeyError: ‘unexpected key “net.“】
下载的预训练模型显示key不对,
2023-04-15 11:11:47
272
原创 Python读取tsv文件
filepath = "..\folder\data.tsv"df = pd.read_csv(filepath)OSError: [Errno 22] Invalid argument: '..\folder\\data.tsv'应该写成filepath = r"..\folder\data.tsv"df = pd.read_csv(filepath)/////////////////////////////////////////////////////////////////////
2022-03-04 20:15:18
1773
原创 Ubuntu 虚拟机无法启动 Oh no Something has gone wrong. A problem has occurred and the system can‘t recover.
Ubuntu 虚拟机无法启动 Oh no! Something has gone wrong. A problem has occurred and the system can’t recover. Please log out and try again.除了经常搜到的驱动问题,还有可能是开启了Hyper-v (比如之前尝试安装了Docker并成功/失败了)解决方法:打开“卸载程序” (可以在控制面板中找到)点击左侧的“启用或关闭Windows功能”
2022-02-09 21:34:07
6680
1
原创 nparray和list的转换
关于nparray和list的转换,可以用np.array和tolist函数,但这两个函数并不会改变原本变量的类型,如下所示。>>> a = [1,2,3]>>> type(a)<class 'list'>>>> import numpy as np>>> np.array(a)array([1, 2, 3])>>> type(a)<class 'list'>>>&
2020-08-19 20:01:47
9118
原创 Latex下align公式换页
\usepackage{amsmath} \begin{document} \begin{align*} \\xxx=xxx \\&=xxx \\&=xxx \\&=xxx\end{align*}\end{document}不需要equation,align里本身就是公式了。参考https://tex.stackexchange.com/questions/51682/is-it-possible-to-pagebreak-aligned
2020-05-09 12:58:02
6414
转载 pip install torch安装torch失败
改用官网的:pip install torch=1.4.0 torchvision=0.5.0 -f https://download.pytorch.org/whl/torch_stable.html链接: https://pytorch.org/.
2020-03-15 23:23:43
8637
5
原创 VS2019下Crypto++安装与调用
Win10系统+Visual Studio 2019+Crypto++8.2.0首先官网下载Crypto++源码https://www.cryptopp.com/#download(或直接github)https://github.com/weidai11/cryptopp/releases/tag/CRYPTOPP_8_2_0打开 cryptest.sln打开cryptlib下的选择x...
2020-02-16 20:22:10
4547
5
原创 google浏览器下remix智能合约中 bytes32[] 类型的输入
谷歌浏览器下使用remix发布智能合约,使用时“bytes32[]”类型总是输不对。如果输入单个数值,则会提示"Error:expected array value",输入列表,也会出现"Error:invalid bytes32 value"的报错,如下图:因为此处的输入不会自动补位,所以必须是刚好64位16进制编码才行,如:[“0x746573740000000000000000000...
2019-09-24 10:45:42
7644
5
原创 solidity:delete函数警告Using delete on an array leaves a gap
使用delete函数删除内容时,remix可能出现警告:“browser/new.sol:39:119:Using delete on an array leaves a gap. The length of the array remains the same. If you want to remove the empty position you need to shift items m...
2019-08-29 17:06:51
958
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人