- 博客(417)
- 资源 (42)
- 收藏
- 关注
原创 LeetCode1584. 连接所有点的最小费用 [Medium]
最小生成树Prim。将顶点分为两个集合,已经选中的和未选中的。对于新选中的顶点 `i` ,判断是否可以缩短到未选中顶点 `j` 的距离 `dist[j]` ;并在所有未选中的顶点中,找到距离 `i` 最近的点 `nearest_j` ,作为下一个选中的顶
2021-09-12 16:32:32 211
原创 Ubuntu安装ohmyzsh
安装git和zshsudo apt-get install git zsh安装ohmyzsh官方安装说明,官方给的命令本质上为下载源代码至~/.oh-my-zh目录。因为github连接常常发生中断,以下使用hub.fastgit.org镜像站进行下载安装,也可直接下载ZIP文件。(base)# sky @ DESKTOP-NJJGMD8 in ~/github [19:04:15]$ git clone https://hub.fastgit.org/ohmyzsh/ohmyzsh.git
2021-07-11 20:05:10 1081
原创 LeetCode1416. 恢复数组 [Hard]
某个程序本来应该输出一个整数数组。但是这个程序忘记输出空格了以致输出了一个数字字符串,我们所知道的信息只有:数组中所有整数都在 [1, k] 之间,且数组中的数字都没有前导 0 。给你字符串 s 和整数 k 。可能会有多种不同的数组恢复结果。按照上述程序,请你返回所有可能输出字符串 s 的数组方案数。由于数组方案数可能会很大,请你返回它对 10^9 + 7 取余 后的结果。
2021-06-27 15:06:50 174
原创 LeetCode1278. 分割回文串 III [Hard]
给你一个由小写字母组成的字符串 s ,和一个整数 k 。请你按下面的要求分割字符串:首先,你可以将 s 中的部分字符修改为其他的小写英文字母。接着,你需要把 s 分割成 k 个非空且不相交的子串,并且每个子串都是回文串。请返回以这种方式分割字符串所需修改的最少字符数。
2021-05-30 16:58:53 129
原创 论文简读《An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale》
An Image is Worth 16x16 Words: Transformers for Image Recognition at Scale (ViT)
2021-05-23 16:40:07 413
原创 LeetCode1187. 使数组严格递增 [Hard]
给你两个整数数组 arr1 和 arr2 ,返回使 arr1 严格递增所需要的最小「操作」数(可能为 0)。每一步「操作」中,你可以分别从 arr1 和 arr2 中各选出一个索引,分别为 i 和 j , 0 <= i < arr1.length 和 0 <= j < arr2.length ,然后进行赋值运算 arr1[i] = arr2[j] 。如果无法让 arr1 严格递增,请返回 -1
2021-05-16 12:22:20 257 1
原创 LeetCode1190. 反转每对括号间的子串 [Medium]
给出一个字符串 s (仅含有小写英文字母和括号)。请你按照从括号内到外的顺序,逐层反转每对匹配括号中的字符串,并返回最终的结果。注意,您的结果中 不应 包含任何括号
2021-05-05 15:28:08 223
转载 [Docker] 常用命令
https://docs.docker.com/engine/reference/commandline/build/查看列出镜像ImageDocsky@sky-X450CC:~$ docker imagesREPOSITORY TAG IMAGE ID CREATED SIZEzsh latest dbeb7011e1a9 5 hours ago 427MBubuntu zsh b5250c
2021-04-18 16:29:28 94
原创 [Docker] Got permission denied while trying to connect to the Docker daemon socket at unix
环境:Ubuntu 20.04使用官方脚本安装: get docker安装完之后,出现问题:sky@sky-X450CC:~$ docker image lsGot permission denied while trying to connect to the Docker daemon socket at unix:///var/run/docker.sock: Get http://%2Fvar%2Frun%2Fdocker.sock/v1.24/images/json: dial unix
2021-04-11 16:10:28 2213
原创 LeetCode1539. 第 k 个缺失的正整数 [Easy]
给你一个 **严格升序排列** 的正整数数组 `arr` 和一个整数 `k` 。请你找到这个数组里第 `k` 个缺失的正整数。
2021-03-28 15:40:16 157
原创 LeetCode1010. 总持续时间可被 60 整除的歌曲
1010. Pairs of Songs With Total Durations Divisible by 60You are given a list of songs where the ith song has a duration of time[i] seconds.Return the number of pairs of songs for which their total duration in seconds is divisible by 60 . Formally, we wa
2021-03-20 20:05:36 102
原创 论文简读《Harmonizing Transferability and Discriminability for Adapting Object Detectors》
CVPR2020 | Code思想:首先文章提出当前基于对抗的方法image and instance levels alignment [7], strong-local and weak-global alignment [44], local-region alignment based on region proposal [62], multi-level feature alignment with prediction-guided instance-level constraint
2021-03-14 22:01:55 849 2
原创 论文简读《Cross-domain Object Detection through Coarse-to-Fine Feature Adaptation》
CVPR 2020思想:强调前景的重要性,在对齐时提高判别器对前景部分的权重(RPN);除了类别不可知的对齐,引入细类别的对齐(Prototype)。Attentionbased Region Transfer (ART)首先对于层lll的对抗损失如下:LADVl=minθGlmaxθDlExs∈DSlog(Dl(Gl(xs)))+Ext∈DTlog(1−Dl(Gl(xt)))% \begin{equation} \begin{aligned} \mathcal{
2021-03-07 20:57:08 401
原创 LeetCode1139. 最大的以 1 为边界的正方形 [Medium]
1139. Largest 1-Bordered SquareGiven a 2D grid of 0 s and 1 s, return the number of elements in the largest square subgrid that has all 1 s on its border, or 0 if such a subgrid doesn’t exist in the grid .Example 1:Input: grid = [[1,1,1],[1,0,1],[1,1,1]
2021-02-08 18:36:58 122
原创 论文简读《RepVGG: Making VGG-style ConvNets Great Again》
多分支的结构往往比单分支结构的性能要好,可能原因是`multi-branch`模型为众多浅层模型的隐式集合。因此作者提出在训练的时候使用`multi-branch`的结构,但是在部署的时候转换为单分支(不改变精度的情况下)。
2021-01-15 21:13:06 816 2
原创 论文简读《Exploring Categorical Regularization for Domain Adaptive Object Detection》
https://arxiv.org/pdf/2003.09152.pdf提出类别正则化框架,主要使用多标签分类来进行实现前景物体的弱监督。It is widely acknowledged that CNNs trained for singlelabel image classification tend to produce high responses on the local regions containing the main objects [38, 40, 39]. Analogou
2021-01-10 10:22:32 244
原创 LeetCode687. 最长同值路径 [Medium]
687. Longest Univalue PathGiven the root of a binary tree, return the length of the longest path, where each node in the path has the same value. This path may or may not pass through the root.The length of the path between two nodes is represented by th
2020-12-05 20:54:09 94
原创 pytorch固定BN层参数
背景:基于PyTorch的模型,想固定主分支参数,只训练子分支,结果发现在不同epoch相同的测试数据经过主分支输出的结果不同。原因:未固定主分支BN层中的running_mean和running_var。解决方法:将需要固定的BN层状态设置为eval。问题示例:环境:torch:1.7.0# -*- coding:utf-8 -*-import torchimport torch.nn as nnimport torch.nn.functional as Fclass Net(nn.M
2020-11-29 19:49:42 5951 5
转载 Latex希腊字母表
小写希腊字母α\alphaα\alphaθ\thetaθ\thetaooooυ\upsilonυυ\upsilonυβ\betaβ\betaϑ\varthetaϑ\varthetaπ\piπ\piϕ\phiϕ\phiγ\gammaγ\gammaι\iotaι\iotaϖ\varpiϖ\varpiφ\varphiφ\varphiδ\deltaδ\deltaκ\kappaκ\kappaρ\rhoρ\rho
2020-11-15 19:33:31 752
原创 LeetCode1288. 删除被覆盖区间 [Medium]
1288. Remove Covered IntervalsGiven a list of intervals , remove all intervals that are covered by another interval in the list.Interval [a,b) is covered by interval [c,d) if and only if c <= a and b <= d .After doing so, return the number of rema
2020-11-07 09:34:32 190
原创 LeetCode1358. 包含所有三种字符的子字符串数目 [Medium]
1358. 包含所有三种字符的子字符串数目 [Medium] [Number of Substrings Containing All Three Characters]
2020-10-24 09:51:02 289
转载 Fusing batch normalization and convolution in runtime
Implementation in PyTorch# -*- coding:utf-8 -*-import torchimport torch.nn as nndef fuse_conv_and_bn(conv, bn): # # init fusedconv = torch.nn.Conv2d( conv.in_channels, conv.out_channels, kernel_size=conv.kernel_siz
2020-10-11 22:29:59 226
原创 LeetCode1371. 每个元音包含偶数次的最长子字符串 [Medium]
1371. Find the Longest Substring Containing Vowels in Even CountsGiven the string s , return the size of the longest substring containing each vowel an even number of times. That is, ‘a’, ‘e’, ‘i’, ‘o’, and ‘u’ must appear an even number of times.Example
2020-09-13 16:15:49 117
原创 LeetCode1334. 阈值距离内邻居最少的城市 [Medium]
1334. Find the City With the Smallest Number of Neighbors at a Threshold DistanceThere are n cities numbered from 0 to n-1. Given the array edges where edges[i] = [fromi, toi, weighti] represents a bidirectional and weighted edge between cities fromi and
2020-09-05 12:11:18 159
pytorch_1.6.0_docs_tutorials.rar
2020-08-01
opencv_contrib345_x64_vc12_vc14_vc15
2018-12-23
opencv_contrib-4.0.0-mingw53_32
2018-11-20
opencv400_vc14_vc15_x86_x64
2018-11-19
opencv343-mingw53_32
2018-10-29
opencv343_vc10_x86_64
2018-10-13
opencv400-alpha
2018-10-13
IrfanView4.51
2018-09-19
tensorflow1.7.1_cpu_x64_vc14_release dll
2018-07-20
opencv342_vc10_vc12_x86_64
2018-07-20
pytorch_1.9.0_docs_tutorials.zip
2021-06-19
pytorch_1.7.0_docs_tutorials.zip
2020-10-28
ChromeStandaloneSetup64_83.0.4103.116.exe
2020-07-12
gdal202.dll/gdal300.dll
2020-01-14
chrome-amd64_79.0.3945.117.deb
2020-01-13
opencv420_contrib_vc14_vc15_vc16_x64.rar
2019-12-25
chrome_73.0.3683.103.deb
2019-04-12
ChromeStandaloneSetup64_72.0.3626.109.exe
2019-02-15
opencv_contrib401_x86_x64_vc14_vc15
2018-12-25
opencv_contrib345_x86_vc12_vc14_vc15
2018-12-23
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人