On

ECS-Centos7登录页面出现Hint: caps lock on,输入大小写字母反了(大小写反转问题)

问题描述:虚拟机Centos7,输入大小写字母反了,开启capslock的时候变成小写字母了,关闭则变成大写了。。。 解决办法:只需要执行:setleds +caps 或 setleds -caps 即可。 如图: ......
大小 ECS-Centos 字母 页面 Centos

[909] Remove duplicated rows based on multiple columns in Pandas

In a Pandas DataFrame, you can remove duplicated rows based on multiple columns using the drop_duplicates() method. Here's how you can do it: import p ......
duplicated multiple columns Remove Pandas

Paper Reading: Drag Your GAN: Interactive Point-based Manipulation on the Generative Image Manifold

为了实现基于 GAN 的交互式的基于点的操作,本文提出了 DragGAN,它解决了监督手柄点向目标移动和跟踪手柄点两个子问题,以便在每个编辑步骤中知道它们的位置。本文模型是建立在 GAN 的特征空间具有足够的区分力以实现运动监督和精确点跟踪的特性之上的,运动监督通过优化潜在代码的移位特征损失来实现的... ......

Educational Codeforces Round 155 (Rated for Div. 2) B. Chips on the Board

给一个 \(n \times n\) 的棋盘,和两个大小为 \(n\) 的 \(a\) \(b\) 数组。\(a_i\) 代表第 \(i\) 列的权值,\(b_i\) 代表第 \(i\) 列的权值。坐标 \((i, j)\) 的权值为 \(a_i + b_j\) 。 现在需要放若干个芯片和到棋盘上, ......
Educational Codeforces Chips Board Round

Install Redis on macOS

Use Homebrew to install and start Redis on macOS This guide shows you how to install Redis on macOS using Homebrew. Homebrew is the easiest way to ins ......
Install Redis macOS on

RuntimeError: Attempting to deserialize object on CUDA device 1 but torch.cuda.device_count() is 1.

问题:服务器上多块卡,使用其中一张训练的模型,在本地预测的时候报错。 解决:在torch.load中加入map_location,指定一块卡 ......

5.4 Bounds on the optimal code length (Shannon-Fano coding)

From section 5.3, we have \(l_i^*=-\log_D p_i\), but it may not be integer, and we should choose \(l_i\) close to \(l_i^*\). So round it up using the ......
Shannon-Fano Shannon optimal Bounds length

CF1628D2 Game on Sum

题目链接(Easy) 题目链接(Hard) Part1 神奇的博弈类型 \(Dp\) 。 我们发现与当前状态有关的量,有且只有 现在是第几轮,还有 Bob 用了几次加的操作 ,这都会影响之后的决策,而和之前的决策无关,换句话说,当前决策有后效性,没有前效性。那我们考虑倒着 \(Dp\). Part2 ......
1628D 1628 Game Sum CF

termux on Android 6.0

前几天在捣鼓我那Android 6.0的老平板,想装上termux,但termux需要至少Android 7.0,搜了许久,才发现termux官方已经给出答案了。 下载好termux后,需要修改$PREDIX/etc/apt/source.list,在Termux on android 5 or 6 ......
Android termux 6.0 on

Display volume of alsa card on i3status

Display volume of alsa on i3status System: gentoo Desktop: i3wm here is my i3status config of volumes: order += "volume master" order += "volume speak ......
i3status Display 3status volume status

On Java 8

On Java 8 OO 在“问题空间”(问题实际存在的地方)的元素与“方案空间”(对实际问题进行建模的地方,如计算机)的元素之间建立理想的“一对一”的映射关系。 Java不需要sizeof()方法获取数据项被分配的字节大小,因为所有类型的大小在不同平台上是相同的。 —— Java本身就是一种“与平 ......
Java On

Codeforces Round 680 (Div. 2, based on Moscow Team Olympiad) B. Elimination

一个比赛有一百人进入决赛,但是需要经过两轮初赛的选拔。初赛的最终结果由两场初赛产生,不幸的是初赛的最终排名被丢失了。 在每场初赛中,参赛者的排名按非升序排序。当两位参赛者的成绩一样,参赛编号更小的靠前。 现在只知道如下信息: 第一场初赛中,第一百名的成绩为 \(a\) 。且第一场初赛中前一百名的选手 ......
Elimination Codeforces Olympiad Moscow Round

OSError: [Errno 28] No space left on device的原因总结

简单总结下碰到这个问题可能的原因: 最常见的,就是磁盘空间真的满了,这个时候你只能rm一些不需要的文件来解决问题 还有可能是inode不足了,这个跟磁盘当初是怎么格式化的有关,如果有太多细碎文件确实有可能出现明明还有空间但是inode却用完了的情况。可以通过df -ih来查看inode使用情况。解决 ......
原因 OSError device Errno space

ST12 Trace – Step by step instruction on how to use it for analysis

ST12介绍 ST12性能分析工具的使用分如下三个步骤: 设置跟踪参数 开始跟踪收集跟踪数据 分析跟踪数据 跟踪参数分类: 跟踪对象(Trace For) 跟踪类型(Type of Trace) 跟踪对象 ST12可以捕获4种类型的数据 “User/Tasks”, “Work Process”, “ ......
instruction analysis Trace Step step

Weighted Nonlocal Laplacian on Interpolation from Sparse Data

目录概符号说明WNLL Shi Z., Osher S. and Zhu W. Weighted nonlocal laplacian on interpolation from sparse data. 2017, J. Sci. Comput. 概 针对 graph laplacian 提出的一 ......

Property ‘includes’ does not exist on type ‘any[]’.

原文链接:https://www.longkui.site/error/property-includes-does-not-exist-on-type-any/4833/ angular项目,TypeScript。 项目正常跑的时候没有问题,打包项目(package)的时候开始报这个错误。 然后定 ......
Property includes exist does type

otImplementedError: "sortBed" does not appear to be installed or on the path, so this method is disabled.

NotImplementedError Traceback (most recent call last) Cell In[10], line 5 3 s = pybedtools.BedTool(args.starrseq[0]).filter(lambda x: float(x[9]) > 1. ......

Codeforces Round 707 (Div. 2, based on Moscow Open Olympiad in Informatics) B. Napoleon Cake

按以下 \(n\) 次操作制作蛋糕。 叠上第 \(i\) 块面包,然后浇上 \(a_i\) 单位的奶油。可以使当前往下 \(a_i\) 块面包沾上奶油。 输出空格隔开的 \(n\) 个数,第 \(i\) 个的 \(0/1\) 代表第 \(i\) 块面包是否沾有奶油。 比较显然的思路可以进行差分修改。 ......

[CF878E]Numbers on the blackboard

E - Numbers on the blackboard 最后的答案肯定为\(\sum_{l\leq i\leq r} 2^{p_i}\times a_i\) 然后这个\(p\)满足以下限制: \(p_i=0\)(\(i=l\)) \(1\leq p_i\leq p_{i-1}+1\)(\(l<i ......
blackboard Numbers 878E 878 the

Codeforces Round 902 (Div. 2, based on COMPFEST 15 - Final Round)

目录写在前面ABCDE写在最后 写在前面 比赛地址:https://codeforces.com/contest/1877。 呜呜铃果唱歌太好听了、、、 我宣布是第二喜欢的声线,第三喜欢是东北切蒲英,第一喜欢绝赞招募中。 这下不得不成为数码推了、、、 A 答案为 \(-\sum a_i\)。 懒得写 ......
Round Codeforces COMPFEST Final based

Go - Finding the Shortest Path on a Graph

Problem: You want to find the shortest path between two nodes on a weighted graph. Solution: Use Dijkstra’s algorithm to find the shortest path betwee ......
Shortest Finding Graph Path the

Install docker on CentOS _base China

yum remove docker // 卸载docker yum install -y yum-utils // 扩展和增强 yum 包管理器 # 配置docker安装源 yum-config-manager --add-repo https://download.docker.com/linux ......
Install CentOS docker China base

Codeforces Round 902 (Div. 2, based on COMPFEST 15 - Final

Codeforces Round 902 (Div. 2, based on COMPFEST 15 - Final A. Goals of Victory 解题思路: 答案为所有元素之和的负数。 代码: #include <bits/stdc++.h> using namespace std; u ......
Codeforces COMPFEST Round Final based

安防视频监控平台EasyCVR出现“no space left on device磁盘空间不足”是什么原因?该如何解决?

由于每个磁盘下的inode节点是有数量上限的,如果有软件一直产生大量的碎片文件就会导致inode节点被占满,无法继续向磁盘进行写入 ......
视频监控 磁盘 原因 EasyCVR device

Codeforces Round 902 (Div. 2, based on COMPFEST 15 - Final Round)

Preface 难得这么好时间的CF,我直接找来队友组队练题 当然比赛的过程没有三人三机,就跟平时训练一样搞了个新号三人一机的写 中间因为溜去先看F了导致E题留给徐神solo因此出的偏慢,不过后面一起讨论了一下还是出了 最后开F结果好家伙我和祁神双双看错题,对着假题意苦战1h最后无奈投降,今天去再看 ......
Round Codeforces COMPFEST Final based

Codeforces Round 902 (Div. 2, based on COMPFEST 15 - Final Round)

比赛连接 打着打着吃饭去了,又掉分了! A. Goals of Victory 题意: 一场比赛有n个球队,每一个队伍匹配一次,球队的效率等于球队的得分数减去对手的得分数,给出n-1个数据,让你求出未给出的那个数据。 思路: 所有球队的效率和为0 代码: #include<bits/stdc++.h ......
Round Codeforces COMPFEST Final based

Codeforces Round 902 (Div. 1, based on COMPFEST 15 - Final Round) A~D

A. Helmets in Night Light 首先注意到一个关键性质 \(b_i \geq 1\),这就意味着当我们花 \(p\) 的代价解锁了 \(b_i\) 最小的后,仅凭接下来的“连锁反应”就能解锁全部的点。注意到我们“连锁反应”的一定是按 \(b_i\) 从小到大排序后的一段前缀(因为 ......
Round Codeforces COMPFEST Final based

ORA-12012 Error on auto execute of job "SYS"."ORA$AT_OS_OPT_SY_<NN> in 12.2 Database

1 错误 2023-10-08T13:11:12.127171+08:00 Errors in file /oracle/diag/rdbms/arch/ARCH2/trace/ARCH2_j000_305066.trc: ORA-12012: error on auto execute of jo ......
quot AT_OS_OPT_SY ORA Database execute

Git基础(Based on ProGit)

Git Git的配置信息 使用git config命令对Git做一些配置。 Git的配置文件等级 Git的配置文件有三个,分别对应不同的影响等级: Linux下 /etc/gitconfig:包含系统上每个用户及他们仓库的通用配置,使用git config --system更改 ~/.gitconf ......
基础 ProGit Based Git on

【Vagrant】 Build PG15 on rhel8

vagrant创建一套single PG15,同时创建一个新的数据库db_pg15 (密同) Vagrant.configure("2") do |config| vms = [ # { name: "app01", box: "centos-8", hostname: "app01", ip: " ......
Vagrant Build rhel8 rhel 15