摘要: // 优先队列 #include<iostream> #include<cstdio> #include<algorithm> #include<vector> #include<queue> #include<set> using namespace std; int main(){ priori 阅读全文
posted @ 2021-10-17 23:17 consolexinhun 阅读(12) 评论(0) 推荐(0) 编辑
摘要: 首先安装 Qt Designer pip install pyqt5-tools 在 PyCharm 中 添加 Qt designer 添加之后,可以通过 pycharm 打开 pycharm 添加 pyuic ,将设计的 ui 文件转化为 py 代码 pyuic 的路径也可以为 uic 的路径 E 阅读全文
posted @ 2021-10-11 17:58 consolexinhun 阅读(112) 评论(0) 推荐(0) 编辑
摘要: 在文件地址栏输入 %appdata% 然后新建 pip 文件夹,再 新建 pip.ini 文件,填入下面的内容 [global] timeout = 6000 index-url = http://pypi.douban.com/simple trusted-host = pypi.douban.c 阅读全文
posted @ 2021-10-11 17:37 consolexinhun 阅读(91) 评论(0) 推荐(0) 编辑
摘要: 下载 picgo,安装 gitee 插件 配置 Gitee 插件 令牌在 Gitee 上的 “私人令牌” 部分 typora 设置上传图片的行为 阅读全文
posted @ 2021-10-11 17:14 consolexinhun 阅读(31) 评论(0) 推荐(0) 编辑
摘要: 在设置里,博客皮肤选择 custom,CSS 页面代码使用下面这个 @import url(https://blog-static.cnblogs.com/files/gshang/gshang.2019.11.19.1.css) screen and (min-width:0px); 阅读全文
posted @ 2021-10-04 15:33 consolexinhun 阅读(42) 评论(0) 推荐(0) 编辑
摘要: fatal: refusing to merge unrelated histories 在 pull 的时候出现了这个错误,说的是远程分支和当前分支没有建立联系, 在命令后面加 --allow-unrelated-histories 就行 比如说 git pull origin master -- 阅读全文
posted @ 2021-09-30 20:17 consolexinhun 阅读(38) 评论(0) 推荐(0) 编辑
摘要: 如果是传输一个目录 接收端先进入一个目录 然后 nc -l 12345 | tar zxvf -,端口采用12345,被占用了就换一个 发送端运行 tar zcvf - dir_path | nc remote_ip 12345 ,这里remote_ip 填写接收端的 ip 这里最好跑到要传输的目录 阅读全文
posted @ 2021-05-17 16:08 consolexinhun 阅读(124) 评论(0) 推荐(0) 编辑
摘要: nohup bash xxx.sh > out.log 2>&1 & 可以让命令后台运行, 输入 tail -f out.log 可以查看输出的结果 这样即使客户端断开了连接,服务端也不会因为客户端的断连而终止程序 另外,在运行 python 程序的时候,最好加上 -u 参数,例如nohup pyt 阅读全文
posted @ 2021-05-17 16:03 consolexinhun 阅读(165) 评论(0) 推荐(0) 编辑
摘要: print(torch.nn.functional.one_hot(t, num_classes=7)) 有个坑,使用的时候必须转换为 torch.int64 类型,不然会报错 t = t.to(torch.int64) 阅读全文
posted @ 2021-01-20 16:48 consolexinhun 阅读(310) 评论(0) 推荐(0) 编辑
摘要: pip安装依赖pydot和graphviz并且安装软件sudo apt install graphviz,有个坑,windows安装软件之后安装的依赖是pydot-ng 注意:模型的第一层需要把形状传进去 import os os.environ['TF_CPP_MIN_LOG_LEVEL'] = 阅读全文
posted @ 2021-01-18 15:27 consolexinhun 阅读(206) 评论(0) 推荐(0) 编辑