ReLU Zero Gradient: Which path does the loss occur

ReLU is defined as max(0,z).

Thematic shorts • IntroductionCollate in 2 self-measured2 First-hand sources
Start Body
Learning objectives and first steps2 objectives 2 first fixes

Try to do it after reading

  • Select the local lead of the negative zone
  • Distinguishing individual cases of loss from long-term failure

Suggested first

  • Vector and Matrix Operations
  • Counts and chain rules

One zero output is not enough to judge that the unit is useless

ReLU is defined as max(0,z). When the pre-activate is negative, the output is zero, and the local lead number usually used is zero. This temporarily prevents a parameter path from receiving a gradient, but does not equal the best advantage of the entire model, let alone the permanent failure of the unit for all inputs. It is important to first identify which variable zero occurs, how many samples are covered and how long it lasts.

Take z = wx+b, w = 1, b = 10-2, enter x = 1. z = 10-1, so ReLU output 0. Regardless of the number of lead points that the subsequent loss will have on this output, the gradient returned along the current ReLU is still zero, and w and b have not been updated on this sample path. If x = 3, z = 1, the local guide is 1 and the unit is able to receive the gradient.

Assuming that a batch contains only x = [0,1], both inputs fall on the negative side, it is not surprising to observe a zero gradient for the entire batch. If this is the case for all training inputs over the long term, and there are no other shared paths to change the parameters, the module may fail to function continuously. An over-renewal pushed bias to a very negative level and was a cause worth checking; You should look back at the parameter trajectory and not just at the current active.

At z = 0, the normal lead number does not exist and the frame selects a given value for calculation. The difference between the centre and the point of zero may be 0.5, which is not inconsistent with the zero selected in a given frame; A numerical gradient examination should avoid the boundary or specify which broad lead should be agreed. It was not sufficient to attribute the limited differentials directly to the framework.

An activation with a small negative slope can provide another path for the number of guides, but a change in the activation will change the function and initialization conditions, not cost-free fixes. It is also possible to check input standardization, bias scales and learning rates. If the unit is shared with other targets, the other paths may still allow it to re-enter the normal area, and a full map needs to be seen.

The scope of application is the mathematical synonym of ReLU in the common eager automatic fraction, which is an artificial structure and does not involve model training results. The active ratio can be recorded on a fixed input set and the parameters updated; The “zero” is not a sufficient basis for deletion in itself.

This example x = 3 p.m. Does the local gradient of w be cut to zero?

No, z = 1 is on the right side and ReLU is leaching 1; The final gradient also depends on the number of triggers for upstream losses.

Do you think units with zero output can be deleted directly?

It cannot be judged by a single input. Coverage of different population groups and time is done first, and it is confirmed that there are other routes or deployment input that may activate it.

Sources and reconciliations

Definitions, methods and interfaces are available.

  1. CS231n — Backpropagation, Intuitions
  2. CS231n — Setting up the data and model

Figures and calculations are reorganized according to this chapter. Mathematical measurements, framework operations and real business effects are described separately in the body of the text.

← Back to the knowledge directory
Ask Max Ask about this site
Ask Max ↗

Opening the assistant…

Paper figure

Photo comments

LEAVE A NOTE

About this photograph

Connecting to the discussion board…

    Comments become public after moderation. You can delete your own comments from this browser.
    No email is required. Clearing cookies prevents this browser from claiming earlier comments.

    MAX WANG / INDEX

    Find something

    Enter a keyword, or explore the directory below.