• ## Simplified regularization of machine learning: L2 regularization

Time：2021-10-19

Please see the following generalization curve, which shows the loss of training set and verification set relative to the number of training iterations Figure 1. Loss of training set and verification set Figure 1 shows that the training loss of a model gradually decreases, but the verification loss eventually increases. In other words, the generalization […]

• ## Detailed explanation of two methods of regular pattern matching in openresty

Time：2021-10-16

preface This article introducesOpenRestyTwo kinds ofregularpattern matching。 First of all, the openresty suite contains two kinds of syntax: one is the openresty syntax mainly based on the FFI API, and the other is the syntax similar to the native Lua scripting language. In the content introduced in this article, the regular pattern matching corresponding to […]

• ## Logistic regression in machine learning: model training

Time：2021-10-14

Loss function of logistic regression The loss function of linear regression is the square loss. The loss function of logistic regression is a logarithmic loss function, which is defined as follows: \displaystyle LogLoss = \sum_{(x,y)\in D} – ylog(y’) – (1-y)log(1-y’) Of which:1. (x, y) \ in D is a dataset containing many labeled samples (x, […]

• ## Training neural networks for machine learning: Best Practices

Time：2021-10-11

This part introduces the failure cases of back propagation algorithm and the common methods of regularized neural network. Failure cases Many common situations will lead to the error of back propagation algorithm. Gradient disappearance The gradient of the lower layer (closer to the input) may become very small. In the depth network, the calculation of […]

• ## Sparse regularization of machine learning: L1 regularization

Time：2021-10-8

Sparse vectors usually contain many dimensions. establishFeature combinationWill result in more dimensions. Due to the use of such high latitude feature vectors, the model may be very large and require a lot of ram.In high latitude sparse vectors, it is best to reduce the weight to exactly 0 as much as possible. A weight of […]

• ## [non negligible] dynamic relu: adaptive parameterized relu (parameter adjustment Record 9) cifar10 ~ 93.71%

Time：2021-10-5

Adaptive parameterized relu is a dynamic relu (dynamic relu), submitted to IEEE Transactions on industrial electronics on May 3, 2019 and hired on January 24, 2020,Published on IEEE official website on February 13, 2020。 In this paperParameter adjustment record 6On the basis of, continue to adjust the super parameters to test the effect of adaptive […]

• ## Simplified regularization of machine learning: lambda

Time：2021-10-3

The model developer adjusts the overall impact of regularization by multiplying the value of the regularization term by the namelambda(also known asRegularization rate）Scalar of. That is, the model developer will perform the following operations: minimize (Loss(Data|Model) + \lambda complexity(Model)) Execute L_ 2 regularization has the following effects on the model Yes, the weight value is […]

• ## JavaScript uses regular to quickly find different characters of two strings

Time：2021-10-3

//by   South of summer [Ctrl + a full selection note: you need to refresh the page to import external JS]

• ## JavaScript to judge the regularity of Chinese

Time：2021-9-28

Regular expression matching Chinese characters: [\ u4e00 – \ u9fa5]Matching double byte characters (including Chinese characters): [^ \ X00 – \ XFF] Copy codeThe code is as follows: <script>  function isChinese(temp)  {   var re = /[^\u4e00-\u9fa5]/;   if(re.test(temp)) return false;   return true;  }  Alert (isChinese (“Chinese”);  </script>

• ## Regularization of removing HTML tags and spaces by ASP

Time：2021-9-24

function nohtml(str)  dim re  Set re=new RegExp         re.IgnoreCase =true         re.Global=True         re.Pattern=”(\<.[^\<]*\>)”         str=re.replace(str,” “)         re.Pattern=”(\<\/[^\<]*\>)”         str=re.replace(str,” “)         str=replace(str,”&nbsp;”,””)        str=replace(str,” “,””)        nohtml=str         set re=nothing  end function

• ## Detailed explanation of PHP regular email statement

Time：2021-9-22

Copy codeThe code is as follows: <?php   if (eregi(“^[_.0-9a-z-][email protected]([0-9a-z][0-9a-z-]+.)+[a-z]{2,3}$”,$email)) {   echo   “Your   E-Mail   Pass the preliminary inspection “;   }   ?>    In this sentence, the first is to apply an eregi function, which is easy to understand. Just look for a book and you’ll get an explanation:  Syntax:   int   ereg(string   pattern,   […]

• ## Implementation of regular script filtering with JS

Time：2021-9-21

(recommended) JS regular knowledge points topic: https://www.jb51.net/article/139831.htm function stripscript(s) {      return s.replace(/<script.*?>.*?<\/script>/ig, ”);  }  Say a little, the master floats by /The content between / is the beginning and end of writing JS regular statements .*? It is a greedy match. If it is not greedy, it is. * match any character, but the greedy one does not contain […]