- 博客(52)
- 收藏
- 关注
原创 Linux gsettings
gsettings提供了对GSetings的命令行操作。GSetings实际上是一套高级API,用来操作dconf。dconf存储着GNOME3的配置,是二进制格式。它做为GSettings的后端系统存在,暴露出低级API。在GNOME2时代,类似的角色是gconf,但它是以XML文本形式存储。更接地气的说法是,dconf是GNOME3的注册表,gsettings是一个查询、读取、设置注册表键值的命令行工具。列出所有schema$ gsettings list-schemas查找某个schem
2021-07-31 22:37:08
706
原创 恼人的Microsoft Word
同样是“单倍行距”,为什么间距会不一样? - querr lee的文章 - 知乎https://zhuanlan.zhihu.com/p/148446917
2021-06-14 22:52:50
135
原创 InfoGAN理论分析帖汇总
Infogan-信息最大化生成对抗网络(理论部分)infoGAN公式推导(信息最大化生成对抗网络(理论部分))InfoGAN中公式5的理解十篇GAN论文的数学分析 by Crazymuse AI
2021-05-08 16:37:55
219
原创 pytorch中的函数摘录
Categorical.log_prob()log_prob takes the log of the probability (of some actions). Example:action_logits = torch.rand(5)action_probs = F.softmax(action_logits, dim=-1)action_probsReturns:tensor([0.1457, 0.2831, 0.1569, 0.2221, 0.1922])Then:dist =
2021-05-01 23:43:14
989
原创 argparse官网文档翻译及整理
This tutorial is intended to be a gentle introduction to argparse, the recommended command-line parsing module in the Python standard library.这篇教程旨在作为 argparse 的入门介绍,此模块是 Python 标准库中推荐的命令行解析模块。–helpimport argparseparser = argparse.ArgumentParser()pars
2021-03-28 14:19:02
291
原创 windows下配置OpenAI-gym&baselines
OpenAI Gym websiteGym is a toolkit for developing and comparing reinforcement learning algorithms. It supports teaching agents everything from walking to playing games like Pong or Pinball.OpenAI Baseline githubOpenAI Baselines is a set of high-quality
2021-03-16 19:04:28
861
1
原创 [TensorFlow] windows同时安装cuda10.0和cuda10.1
base环境中的TensorFlow版本为2.0,已经安装了cuda10.1。在虚拟环境tf1.4中,TensorFlow版本为1.4,import tensorflow as tf 报错显示ImportError: Could not find 'cudart64_100.dll'. TensorFlow requires that this DLL be installed in a directory that is named in your %PATH% environment variable
2021-03-16 18:18:46
802
1
原创 在typora中实现文本和图片并排显示
实现代码为:<div class="row"> <div class="column" style="float:left;width:75%"> <u>Consider the familiar child’s game of tic-tac-toe.</u> Because a skilled player can play so as never to lose, let us assume that we are .
2020-11-13 11:30:51
2269
原创 CF EDU 22 F. Bipartite Checking (时间分治线段树+可撤销并查集+二分图判定)
CF EDU 22 F. Bipartite Checking∗2500*2500∗2500题意:You are given an undirected graph consisting of nnn vertices. Initially there are no edges in the graph. Also you are given qqq queries, each query either adds one undirected edge to the graph or removes
2020-11-03 15:17:23
183
原创 C++/JAVA/Python语法层面的差别
因为做题时,经常会混用几种语言的语法,导致难以察觉的错误,特记录如下:1 三目运算符C++int main() { int x = 100; int y = x > 0 ? x : -x; int z = x ? x > 0 : -x; cout << "y : " << y << ",z : " << z << endl;}输出:y : 100, z : 1JAVApublic cla
2020-10-18 22:20:46
143
原创 Ubuntu磁盘空间清理
https://www.omgubuntu.co.uk/2016/08/5-ways-free-up-space-on-ubuntu
2020-10-10 17:54:01
157
转载 Visual Studio Code formatting for “{ }”
原文链接问题I’m on Ubuntu. When I write C++ code in Visual Studio Code it automatically lints likeif (condition == true){ DoStuff();}Instead I want to do like:if (condition == true) { DoStuff();}How do I do that?I’ve already installed the C/C++ e
2020-10-05 14:34:54
131
原创 VScode使用bit/stdc++.h头文件
1.创建c_cpp_properties.json文件2编辑c_cpp_properties.json文件搜索包含bits/stdc++.h的文件夹目录:将路径写入"includePath":{ "configurations": [ { "name": "Win32", "includePath": [ "${workspaceFolder}/**", "D:
2020-10-05 12:00:46
970
原创 JUnit vs Mockito
JUnit vs Mockitoreference:MOCKITO: What is it and how is it different from Junitauthor:GhostCatJUnit is a framework that helps with writing and running your unit tests.JUnit是一个帮助编写和运行单元测试的框架。Mockito (or any other mocking tool) is a framework that yo
2020-09-05 18:10:28
843
原创 数学基础
1.已知两边及夹角,求第三边长a→−b→=c→(a→−b→)2=c→2a2+b2−2abcosα=c2\overrightarrow{a}-\overrightarrow{b}=\overrightarrow{c}\\(\overrightarrow{a}-\overrightarrow{b})^2=\overrightarrow{c}^2\\a^2+b^2-2ab\cos\alpha=c^2a−b=c(a−b)2=c2a2+b2−2abcosα=c2...
2020-09-05 11:26:16
139
原创 Excel导出SQL语句(包含时间格式的处理)
2020-08-31 00:00:00 1598803200 2020/8/31 0:00 Number of Risk Merchants 2 =CONCATENATE("insert into `mytable` (`gmt_occur`,`name`,`count`) values ('",A3,"','",D3,"','",E3,"');")显示结果为:insert into `mytable` (`gmt_occur`,`name`,`count`) val
2020-09-04 16:01:50
928
原创 ubuntu16安装Python3.7
ubuntu16系统自带了python2.7和python3.5;不要卸载ubuntu自带的python版本;ubuntu下不同版本的python可以共存,可直接安装python3.7。1.升级包索引和软件sudo apt updatesudo apt upgrade -y2.安装编译所需包sudo apt install build-essential zlib1g-dev libncurses5-dev libgdbm-dev libnss3-dev libssl-dev libreadli
2020-08-29 18:18:46
2202
原创 有趣的小技巧
1.自定义B站播放速度想随意调节B站倍速播放,谷歌浏览器按f12,点选console输入 document.querySelector('video').playbackRate = 3;按下回车即可3倍速播放,想要多少的速度自己调节。
2020-08-07 11:42:06
62
原创 Window安装JAVA
JAVA下载https://www.oracle.com/java/technologies/javase-downloads.html系统变量配置
2020-07-16 22:43:29
136
原创 Latex使用技巧
1 用空格补齐一行\hspace*{\fill} 2 align 和align*align公式自动标号align*公式不标号3 \begin{split}\begin{align}A\\B\end{align}这个A式和B式将会各有一个标号\begin{align}\begin{split}...此时上式一共只有一个标号4调整图片和上下文的空白大小\begin{figure}[H]\setlength{\belowcaptionskip}{-0.5cm} \end{
2020-06-11 15:41:11
641
翻译 nginx学习笔记(2——负载均衡)
关于nginx:点击参考Using nginx as HTTP load balancer介绍(Introduction)跨多个应用程序实例的负载平衡是一种用于优化资源利用率,最大化吞吐量,减少延迟和确保容错配置的常用技术。可以将nginx用作非常有效的HTTP负载平衡器,以将流量分配到多个应用程序服务器,改善Web应用程序的性能,可伸缩性和可靠性。负载均衡方法nginx支持以下负载平衡机制(或方法):轮循:对应用程序服务器的请求以轮循方式分配,连接最少:将下一个请求分配给活动连接数最少的
2020-05-28 10:52:22
155
原创 PyQt调用JavaScript代码时传递参数的类型为列表
在PyQt5对象中访问JavaScript的核心代码如下:QWebEnginePage.runJavaScript(str,Callable);可以看到,传递参数只能是字符串类型。所以我们可以采用在Pyqt端列表转字符串,在JavaScript端字符串转列表的方式。如想要传递的列表为:obj=[["hello","world"],["banni"],["hahaha","!"]]PyQt端代码为:for i in range(len(obj)): obj[i]="+".join(obj[
2020-05-21 10:22:57
716
原创 HTML——下拉列表
<!DOCTYPE html><html lang="en"><head> <meta charset="UTF-8"> <title>Document</title></head><body> <select id="video"><!--下拉列表框--> <option>选项1</option> <op.
2020-05-20 23:26:22
285
翻译 nginx学习笔记(1——入门)
关于nginx:点击参考nginx有一个主进程和多个工作进程。主进程用于阅读和评估配置,并且维护工作进程。工作进程用于实际处理请求。nginx使用基于事件的模型和依赖于操作系统的机制在工作进程之间有效地分发请求。工作进程的数量在配置文件中定义,可以针对给定的配置进行固定,也可以根据可用的CPU内核数量自动调整。nginx及其模块的工作方式在配置文件中确定。 默认情况下,配置文件名为nginx.conf,并放置在目录/usr/ local/nginx/conf,/etc/nginx或/usr/local/
2020-05-13 15:38:08
172
原创 git command
上传本地项目到GitHubmkdir democd demoecho "# demo" >> README.mdgit init //把这个目录变成Git可以管理的仓库git add README.md //文件添加到仓库git add . //不但可以跟单一文件,还可以跟通配符,更可以跟目录。一个点就把当前目录下所有未追踪的文件全部add了(空目录不会被添加)git...
2020-02-23 10:09:54
130
原创 python package
1.conda 换源安装换成清华源。conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/free/conda config --add channels https://mirrors.tuna.tsinghua.edu.cn/anaconda/pkgs/main/conda conf...
2020-02-10 18:06:42
354
原创 Codeforces E. Permutation Separation
类似二维偏序题意:给定111到nnn的一个排列p1,p2,...,pnp_1,p_2,...,p_np1,p2,...,pn,移动花费aia_iai。求先将排列划分为两个非空集合——p1,p2,...pkp_1,p_2,...p_kp1,p2,...pk和pk+1,pk+1,..pnp_{k+1},p_{k+1},..p_npk+1,pk+1,..pn,1≤k<...
2020-02-08 12:16:52
257
原创 Spyder Tips
Header template for new empty fileHere is how to change it:“Tools” Menu > “Preferences” entry > “Editor” page > “Advanced settings” tab > “Edit template for new modules” button...
2020-02-06 12:20:19
299
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人