摘要:
model = Model() model(input) 直接调用Model类中的forward(input)函数,因其实现了__call__ 举个例子 1 import math, random 2 import numpy as np 3 4 import torch 5 import torc 阅读全文
摘要:
docker run -mysqltest -d -p 3306:3306 mysql/mysql-server 阅读全文
摘要:
由于数字之间的关系,在题目中有限定递增等类似条件时,还可以通过单调栈等类似思想再对算法进行时间复杂度的降维优化 1964. 找出到每个位置为止最长的有效障碍赛跑路线 class Solution: def longestObstacleCourseAtEachPosition(self, obsta 阅读全文
摘要:
树状数组 更高效地对点、区间进行查询、更新 ref:树状数组详解 k为i的二进制中从低位到高位的连续零长度 C[i] = A[i-2k+1] + A[i-2k+2] + ... + A[i] 2k = i&(-i) sum[i] = C[i] + C[i - 2k1] + C[i - 2k1 - 2 阅读全文
摘要:
https://files.cnblogs.com/files/yuelien/rl-sc.pptx 阅读全文
摘要:
via: stackoverflow Having two different functions is a convenience, as they produce the same result. The difference is simple: For sparse_softmax_cros 阅读全文
摘要:
tf.keras.Sequential groups a linear stack Models into Sequential Here are quick starts for the beginners and experts respectively: MINIST Recongnizati 阅读全文
摘要:
1 import copy 2 from cmath import inf, log 3 import numpy as np 4 5 class Solution: 6 suffix_list = None 7 tree_list = None 8 shuffle_list = None 9 op 阅读全文
摘要:
refs: Sequential Minimal Optimization for SVM - MITftp.ai.mit.edu › tlp › svm › svm-smo › smo SVM by Sequential Minimal Optimization (SMO)pages.cs.wis 阅读全文
摘要:
class Solution: flag = False # [low, high) lastdiv = -1 def helper(self, low1: int, high1: int, low2: int, high2: int, s1:[], s2:[]) -> int: div1 = -1 阅读全文