- 2024-04-06P10244 String Minimization 题解
P10244StringMinimization题意给你四个长度为\(n\)的字符串,分别是\(abcd\)。你可以选择一个\(i\)然后交换\(a[i]\)和\(c[i]\),并交换\(b[i]\)和\(d[i]\)。求在\(a\)的字典序尽量小的前提下,\(b\)字典序最小是什么。思路本题并不难。只需要在\(a[i]>c[i]\)
- 2024-01-13SHARPNESS-AWARE MINIMIZATION FOR EFFICIENTLY IMPROVING GENERALIZATION论文阅读笔记
Intro在训练集上最小化损失很可能导致泛化性低,因为当今模型的过参数化会导致trainingloss的landscape异常复杂且非凸,包含很多local/globalminima,因此优化器的选择至关重要。losslandscape的几何性质(特别是minima的flatness)与泛化性有着紧密的联系,为此作者提出了SAM(Sharpness-A
- 2023-07-17题解 Yet Another Minimization Problem
YetAnotherMinimizationProblem神仙题。第一眼看上去就是DP。定义\(f_{i,j}\)表示当前点\(i\),分\(j\)段的最小费用。\(f_{i,j}=\min(f_{i,j},f_{k,j-1}+val_{k+1,i})\)然后发现复杂度\(O(n^2k)\),直接T飞,需要优化。我们发现\(j\)那一维可以滚掉,也就是只考虑第
- 2023-07-10Regret Minimization Experience Replay in Off-Policy Reinforcement Learning
发表时间:2021(NeurIPS2021)文章要点:理论表明,更高的hindsightTDerror,更加onpolicy,以及更准的targetQvalue的样本应该有更高的采样权重(ThetheorysuggeststhatdatawithhigherhindsightTDerror,betteron-policinessandmoreaccuratetargetQvalueshouldbea
- 2023-07-03AtCoder Regular Contest 153 E Deque Minimization
洛谷传送门AtCoder传送门我们考虑给定\(X\),如何贪心地求\(f(X)\)。队列为空时加入队首或队尾都是一样的。队列不为空,设队首为\(c\)。因为我们的目标是最小化字典序,于是如果\(X_i\lec\),我们把\(X_i\)加入队首,否则加入队尾。由此也容易发现,加入队首的数一定单调不升。
- 2023-06-17Yet Another Minimization Problem(CF1637D)
\(\text{Des}\)Youaregiventwoarrays$a$and$b$,bothoflength$n$.Youcanperformthefollowingoperationanynumberoftimes(possiblyzero):selectanindex$i$($1\leqi\leqn$)andswap$a_i$and$b_i$.Let'sdefi
- 2023-05-20AtCoder Regular Contest 130 C Digit Sum Minimization
洛谷传送门AtCoder传送门分类讨论,但是写起来挺答辩的。首先发现我们要使进位尽量多。特判怎么重排都没有进位的情况(\(a_i+b_i<10\))。然后枚举个位选的两个数字,并且要求它们和\(\ge10\)。如果当前位两个位都有数字,那么从小到大枚举数位的和\(\in[9,18]\);如果有数字
- 2023-05-02迁移学习《mixup: Beyond Empirical Risk Minimization》
论文信息论文标题:mixup:BeyondEmpiricalRiskMinimization论文作者:TakeruMiyato,S.Maeda,MasanoriKoyama,S.Ishii论文来源:2018ICLR论文地址:download 论文代码:download视屏讲解:click
- 2023-02-26CF1637D Yet Another Minimization Problem
定义某数组xx的权值为 sum{sum{a[i]+b[i]}}i<j<n 现在,给定两个长度为nn的数组a,ba,b。你可以执行若干次操作,每次操作选择一个下标ii,并交换ai,bi。求在
- 2022-12-12[ABC281F] Xor Minimization
divclass="part">ProblemStatementYouaregivenasequenceofnon-negativeintegers$A=(a_1,\ldots,a_N)$.Letusperformthefollowingoperationon$A$just
- 2022-10-15[CF868F]Yet Another Minimization Problem
做题时间:2022.10.15\(【题目描述】\)给定一个长度为\(n(2\leqn\leq10^5)\)的序列,把他分成\(k(2\leqk\leq\min(n,20))\)个子段,每个子段的花费是其中相同元素的对