首页 > 其他分享 >"deepleraning.ai" study Notes P51 为什么正则化可以减少过拟合

"deepleraning.ai" study Notes P51 为什么正则化可以减少过拟合

时间:2023-09-04 09:45:28浏览次数:47  
标签:function linear tanh ai big study activation P51 lambda

# L2 regulization

* what we have done is add a regularization item in the cost function

* the cost function in neural network will be 

 # why is it that shrinking the L2 norm or the parameters might cause less overfitting?

--------------------------------

### 1. one piece of intuition

* if u crank regularization lambda to be really big, they'll be really inventivized to set the weight matrix W to be reasonably close to zero

* so, weights for a lot of hidden units wiil be close to zero that's basically zeroing out a lot of impact of these hidden units

 _the impact of lambda value

 

 as shown in the upper image, as the increasing of lambda, the performance of model will be changed form right to the left 

so, there will be an intermediate value of lambda that results in result closer to this just right case in the middle

----------------------------------------------

### 2. the second piece of intuition for why regularization helps prevent overfitting

* assume that we're using tanh activation function

#### tanh activation function

 * when z is very small, it's just using the linear regime of the tanh function

* only if z is allowed to wander up to larger values or smaller values, the activation function starts to become less linear

-------------------------

so, if we set the lambda very big, then the follow chain action occur

big lambda -> small weight -> small z(the input of activation) -> use the linear regime of the tanh function -> the NN is roughly linear -> basically a linear model and couldn't overfitting

------------------------------------------------

视频链接:1.5为什么正则化可以减少过拟合_哔哩哔哩_bilibil

标签:function,linear,tanh,ai,big,study,activation,P51,lambda
From: https://www.cnblogs.com/heMing-H/p/17676094.html

相关文章

  • 我的 Kafka 旅程 - 基于账号密码的 SASL+PLAIN 认证授权 · 配置 · 创建账号 · 用户
    本文基于Kafka3.0+的KRaft模式来阐述默认的Kafka不受认证约束,可不用账号就可以连接到服务,也就是默认的PLAIN方式,不需要认证;配置了SASL认证之后,连接Kafka只能用凭证连接登录。SASL支持的认证方式有多种:GSSAPI,PLAIN,SCRAM-SHA-256,SCRAM-SHA-512,OAUTHBEARERGSSAPI......
  • [AIGC] a brief summary for this week, replica and localGPT
    Inthisweek,Iexperiencedtwomainprojects,replicaandlocalGPT.replicademo:Replicaistryingtobuildamodelhub.Ihaven'tdiveinitsstructureyet,butIwilldomoreresearchbecauseIbeliveit'llbemorepopularandwidelyused......
  • Failed to start bean 'documentationPluginsBootstrapper'; nested exception is jav
    2023-09-0322:53:53.622WARN20788---[main]ConfigServletWebServerApplicationContext:Exceptionencounteredduringcontextinitialization-cancellingrefreshattempt:org.springframework.context.ApplicationContextException:Failedtostartbean......
  • 2023.35 AI检测器
    随着AIGC的火热,越来越多的内容是AI生成的,效率很高,但可能是会错。网上国外有人因为看到了AI创作的毒蘑菇的内容而误食了蘑菇中毒。要避免这种问题,我们要多方求证看到的内容,识别并谨慎对待AI生成的内容。可以用哪些方法识别AI创作的内容呢?1.检查语法和拼写错误:AI生成的内容可能会......
  • 支持AI视频处理的高容量流媒体加速卡方案
     //  编者按: 实况直播业务随着流媒体市场的发展增长迅速。与传统流媒体“一对多”的模式不同,直播流媒体高交互的特性和“多对多”的架构对时延的要求越来越高,传统基础设施部署和硬件已经不能高效处理这类需求。在此背景下,AMD专为直播互动流媒体处理打造的新一代Alveo™MA35D......
  • k8s安装etcd出现Job for etcd.service failed......"journalctl -xe" for details.
    错误如下先按照提示,输入journalctl-xe看一些详细信息1、针对:startrequestrepeatedtooquicklyforetcd.service错误,解决办法如下vi/usr/lib/systemd/system/etcd.service在[service]部分添加:RestartSec=5(参数作用:如果服务需要被重启,这个参数的值为服务被重启前的......
  • CF838D Airplane Arrangements 题解
    题意一架飞机有\(n\)个座位排成一列,有\(m\)名乘客(\(m\leqn\))依次上飞机。乘客会选择一个目标座位(两人可以选同一个目标座位),然后选择从前门或者后门上飞机,上飞机后,他们会走到自己的目标座位,如果目标座位已经有人坐了,他们会继续往前走,在走到第一个空位后坐下。如果走到最后......
  • Tail Lamp V1 Develop Log
    山地车尾灯8x8led   带加速感应 长续航1,xmc1404MCU2,BQ240403,TLP757P334,TPS612305,MPU60506,26650电池7,LED矩阵8,USB接口主体结构        5V                       2.8-4.2V                    5V        ......
  • 华为云FunctionGraph函数工作流—— “Serverless“遇见”AI,释放AI生产力
    5月26日-27日,由msup主办的2023年A2M峰会在上海南新雅皇冠假日酒店盛大举行。本次A2M峰会以“AIGC时代下的AI落地实践、数据智能和基础架构演进”为主题,邀请了100余位行业专家从支撑数字化转型的几个关键技术切面入手,甄选前沿有典型代表的84个技术创新及研发实践的架构案例,分享他们......
  • (2023羊城杯)ai和nia的交响曲wp
    第二个框就不说了,追踪第一个框的http流,发现flag1.png 提取以后得到 通过观察,可以得出规律,每八行出现的横线是因为ascii数据按列写,而ascii可见字符最高位恒为0,所以首位肯定是黑像素(诚挚邀请大家学python以外还要学一下matlab,相对更方便。。) 解码后有......