zoukankan      html  css  js  c++  java
  • 优化算法与特征缩放

    特征缩放
    目的
    由于原始数据的值范围变化很大,在一些机器学习算法中,如果没有标准化,目标函数将无法正常工作。例如,大多数分类器按欧几里德距离计算两点之间的距离。如果其中一个要素具有宽范围的值,则距离将受此特定要素的控制。因此,应对所有特征的范围进行归一化,以使每个特征大致与最终距离成比例。
    应用特征缩放的另一个原因是梯度下降与特征缩放比没有它时收敛得快得多。
    
    
    In statistics and applications of statistics, normalization can have a range of meanings.[1] In the simplest cases, normalization of ratings means adjusting values measured on different scales to a notionally common scale, often prior to averaging. In more complicated cases, normalization may refer to more sophisticated adjustments where the intention is to bring the entire probability distributions of adjusted values into alignment. In the case of normalization of scores in educational assessment, there may be an intention to align distributions to a normal distribution. A different approach to normalization of probability distributions is quantile normalization, where the quantiles of the different measures are brought into alignment.
    
    In another usage in statistics, normalization refers to the creation of shifted and scaled versions of statistics, where the intention is that these normalized values allow the comparison of corresponding normalized values for different datasets in a way that eliminates the effects of certain gross influences, as in an anomaly time series. Some types of normalization involve only a rescaling, to arrive at values relative to some size variable. In terms of levels of measurement, such ratios only make sense for ratio measurements (where ratios of measurements are meaningful), not interval measurements (where only distances are meaningful, but not ratios).
    
    In theoretical statistics, parametric normalization can often lead to pivotal quantities – functions whose sampling distribution does not depend on the parameters – and to ancillary statistics – pivotal quantities that can be computed from observations, without knowing parameters.
    
    在统计学和统计学应用中,规范化可以有一系列含义。[1]在最简单的情况下,打分的标准化意味着在取平均前将不同量纲的观测值调整到统一量纲下。
    在更复杂的情况下,归一化可以指更复杂的调整,主要目的是要将不同维度的数据在分布层面做到概率对齐。
    一般场景下归一化会有意将分布与正态分布对齐,比如教育评估、身高统计。
    概率分布归一化的差异点往往是分位数归一化,标准化过程中不同维度间的分位数将被对齐。
    
    在统计学的另一种用法中,归一化是指将维度、数据进行缩放、转换,
    通过比较不同相关维度间标准化结果,缩放到同一空间中,达到消除不同数据之间异常分布导致的不良影响,类似的时序数据中的异常分布也会被消除。
    
    某些类型的规范化仅涉及重新缩放,以获得相对于某个大小变量的值。就测量水平而言,这样的比率仅对比率测量(其中测量的比率是有意义的)有意义,而不是间隔测量(其中仅距离是有意义的,而不是比率)。
    
    在理论统计中,参数标准化通常可以作用于两种情况:关键量和辅助统计;
    其中关键量是采样分布不依赖于参数的函数;辅助统计代表在不知道参数配置的情况下关键量由观测值计算推导。
    
    • AdaGrad
    学习率逐参数的除以历史梯度平方和的平方根,使得每个参数的学习率不同 
    
    1.简单来讲,设置全局学习率之后,每次通过,全局学习率逐参数的除以历史梯度平方和的平方根,使得每个参数的学习率不同
    
    2.效果是:在参数空间更为平缓的方向,会取得更大的进步(因为平缓,所以历史梯度平方和较小,对应学习下降的幅度较小)
    
    3.缺点是,使得学习率过早,过量的减少
    
    4.在某些模型上效果不错。
    
    
    Karpathy做了一个这几个方法在MNIST上性能的比较,其结论是: 
    adagrad相比于sgd和momentum更加稳定,即不需要怎么调参。而精调的sgd和momentum系列方法无论是收敛速度还是precision都比adagrad要好一些。在精调参数下,一般Nesterov优于momentum优于sgd。而adagrad一方面不用怎么调参,另一方面其性能稳定优于其他方法。
    

    img

  • 相关阅读:
    关于轨道交通的一些知识点和关键词
    关于芯片的一些关键词
    关于ADC采集
    Linux记录
    在VMware运行Linux下,密码错误的原因
    气体传感器
    AD采集问题
    Maven [ERROR] 不再支持源选项 5,请使用 7 或更高版本的解决办法
    Maven 专题(九):后记
    Maven 专题(六):Maven核心概念详解(二)
  • 原文地址:https://www.cnblogs.com/suanec/p/11231904.html
Copyright © 2011-2022 走看看