```{=html}
<svg viewBox="0 0 800 320" style="max-width: 100%; height: auto;">
<title>Sigmoid 与 ReLU 激活函数</title>
<desc>Sigmoid函数呈S形,将值压缩到0和1之间。ReLU函数在输入小于0时为0,大于0时呈线性增长。</desc>
<style>
.axis { stroke: #3c4043; stroke-width: 2; }
.grid { stroke: #e0e0e0; stroke-width: 1; stroke-dasharray: 4,4; }
.label { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif; font-size: 16px; text-anchor: middle; fill: #3c4043; }
.title { font-size: 20px; font-weight: bold; }
.sigmoid-line { stroke: #4285F4; stroke-width: 3.5; fill: none; }
.relu-line { stroke: #EA4335; stroke-width: 3.5; fill: none; }
</style>
<text x="400" y="35" class="label title">ReLU的简洁性与效率使其成为现代神经网络的首选</text>
<!-- Grid and Axes -->
<line x1="100" y1="260" x2="700" y2="260" class="axis"/>
<line x1="400" y1="60" x2="400" y2="280" class="axis"/>
<line x1="100" y1="160" x2="700" y2="160" class="grid"/>
<line x1="100" y1="60" x2="700" y2="60" class="grid"/>
<text x="715" y="265" class="label">z</text>
<text x="380" y="55" class="label">g(z)</text>
<text x="400" y="280" class="label">0</text>
<text x="380" y="165" class="label">0.5</text>
<text x="380" y="65" class="label">1.0</text>
<!-- Curves -->
<path d="M 100.0,159.50547536867305 102.0066889632107,159.4852766917202 104.01337792642141,159.46425522267052 106.02006688963212,159.4423776297535 108.02675585284283,159.41960924629225 110.03344481605353,159.39591401852468 112.04013377926418,159.3712544514928 114.04682274247489,159.34559155293735 116.0535117056856,159.3188847751346 118.0602006688963,159.2910919546102 120.066889632107,159.26216924966457 122.07357859531771,159.23207107564232 124.08026755852842,159.2007500378792 126.08695652173913,159.16815686225644 128.09364548494983,159.13424032329462 130.10033444816054,159.09894716971635 132.1070234113712,159.0622220474081 134.11371237458195,159.02400741971044 136.1204013377926,158.98424348496636 138.12709030100336,158.94286809125768 140.13377926421407,158.89981664825908 142.14046822742478,158.85502203614155 144.14715719063545,158.80841451145616 146.15384615384616,158.75992160993223 148.16053511705687,158.70946804612433 150.16722408026757,158.65697560984518 152.17391304347828,158.60236305932418 154.18060200668896,158.54554601103393 156.18729096989966,158.48643682613104 158.19397993311037,158.42494449346114 160.20066889632108,158.36097450908346 162.20735785953178,158.294428752275 164.2140468227425,158.22520535798103 166.22073578595317,158.15319858568546 168.22742474916387,158.0782986846822 170.23411371237458,158.00039175573792 172.2408026755853,157.91935960914603 174.247491638796,157.83507961918258 176.25418060200667,157.74742457498724 178.26086956521738,157.65626252790548 180.26755852842808,157.56145663534286 182.2742474916388,157.46286500119874 184.2809364548495,157.3603405129642 186.2876254180602,157.25373067558863 188.29431438127094,157.14287744224058 190.3010033444816,157.0276170421113 192.30769230769232,156.9077798054353 194.314381270903,156.78318998592871 196.32107023411373,156.6536655808764 198.32775919732438,156.51901814913083 200.33444816053512,156.37905262731982 202.34113712374582,156.23356714459788 204.34782608695653,156.08235283631637 206.3545150501672,155.92519365702975 208.36120401337791,155.76186619330227 210.36789297658862,155.59213947682872 212.37458193979936,155.41577479843528 214.38127090301003,155.23252552358306 216.38795986622074,155.0421369100568 218.39464882943145,154.84434592858474 220.40133779264215,154.63888108720337 222.40802675585286,154.42546226025115 224.41471571906357,154.20380052295204 226.42140468227424,153.973597992627 228.42809364548495,153.7345476776567 230.43478260869566,153.48633333540388 232.44147157190636,153.2286293403964 234.44816053511707,152.9611005641654 236.45484949832775,152.68340226823264 238.46153846153845,152.39518001184098 240.46822742474916,152.096069576129 242.47491638795987,151.78569690655644 244.48160535117057,151.46367807549805 246.48829431438128,151.129619267035 248.49498327759198,150.7831167860859 250.5016722408027,150.42375709413338 252.5083612040134,150.05111687391468 254.51505016722408,149.66476312555784 256.52173913043475,149.26425329675368 258.5284280936455,148.84913544966133 260.53511705685617,148.41894846734502 262.54180602006693,147.97322230263694 264.5484949832776,147.51147827240607 266.5551839464883,147.03322940029196 268.561872909699,146.53798081102724 270.5685618729097,146.02523017952436 272.5752508361204,145.49446823793724 274.5819397993311,144.9451793439257 276.5886287625418,144.37684211334437 278.5953177257525,143.78893012054976 280.60200668896323,143.18091266946152 282.60869565217394,142.5522556384276 284.61538461538464,141.9024224018218 286.6220735785953,141.23087483114577 288.62876254180605,140.53707437820842 290.6354515050167,139.82048324271616 292.6421404682274,139.08056562631862 294.6488294314381,138.31678907481722 296.6555183946488,137.52862590985364 298.66220735785953,136.71555475094942 300.66889632107024,135.8770621282638 302.67558528428094,135.01264418587388 304.68227424749165,134.12180847475634 306.68896321070235,133.20407583396266 308.695652173913,132.25898235773113 310.70234113712377,131.28608144546854 312.7090301003344,130.28494593066384 314.7157190635451,129.25517028386884 316.72240802675583,128.19637288390038 318.72909698996654,127.1081983503899 320.73578595317724,125.99031992973586 322.74247491638795,124.84244192541064 324.74916387959865,123.6643021624451 326.7558528428094,122.45567447477276 328.76254180602007,121.21637120297194 330.7692307692308,119.94624568881576 332.7759197324415,118.64519475193782 334.7826086956522,117.3131611328653 336.7892976588629,115.95013588567878 338.7959866220736,114.5561607026464 340.8026755852843,113.13133015237221 342.809364548495,111.67579381231106 344.8160535117057,110.18975827595884 346.8227424749164,108.6734890146472 348.82943143812713,107.12731207367304 350.8361204013378,105.55161558249762 352.8428093645485,103.94685105897328 354.8494983277592,102.31353448801158 356.8561872909699,100.65224715581036 358.8628762541806,98.9636362217157 360.8695652173913,97.2484150110168 362.876254180602,95.50736301345538 364.8829431438127,93.74132557397957 366.88963210702343,91.95121326427288 368.89632107023414,90.13800092583365 370.90301003344484,88.3027263778507 372.9096989966555,86.4464887857955 374.9163879598662,84.57044668950239 376.9230769230769,82.67581569250518 378.9297658862876,80.7638658175048 380.9364548494983,78.83591853601787 382.943143812709,76.89334348345875 384.94983277591973,74.93755487408987 386.95652173913044,72.97000763339207 388.96321070234114,70.99219326840968 390.96989966555185,69.0056354994653 392.97658862876256,67.01188567927362 394.98327759197326,65.01251802786408 396.98996655518397,63.00912471381467 398.9966555183947,61.003310814059745 401.0033444816054,58.9966891859402 403.0100334448161,56.990875286185286 405.0167224080268,54.987481972135896 407.0234113712375,52.98811432072634 409.03010033444815,50.99436450053466 411.03678929765886,49.00780673159032 413.04347826086956,47.02999236660793 415.05016722408027,45.062445125910145 417.056856187291,43.106656516541236 419.0635451505017,41.16408146398216 421.0702341137124,39.23613418249519 423.0769230769231,37.32418430749479 425.0836120401338,35.42955331049761 427.0903010033445,33.553511214204505 429.09698996655516,31.697273622149282 431.10367892976586,29.861999074166334 433.11036789297657,28.048786735727106 435.1170568561873,26.258674426020434 437.123745819398,24.492636986544625 439.1304347826087,22.751584988983183 441.1371237458194,21.036363778284283 443.1438127090301,19.34775284418967 445.1505016722408,17.686465511988388 447.1571906354515,16.053148941026734 449.1638795986622,14.448384417502382 451.17056856187287,12.872687926326961 453.17725752508363,11.32651098535274 455.18394648829434,9.810241724041163 457.19063545150505,8.324206187688901 459.19732441471575,6.868669847627757 461.20401337792646,5.443839297353577 463.21070234113716,4.0498641143211955 465.21739130434787,2.686838867134668 467.2240802675585,1.3548052480621493 469.2307692307693,0.05375431118420693 471.23745819397993,-1.2163712029719704 473.24414715719064,-2.455674474772792 475.25083612040135,-3.6643021624451535 477.25752508361205,-4.842441925410611 479.26421404682276,-5.990319929735847 481.27090301003346,-7.108198350389898 483.27759197324417,-8.19637288390038 485.2842809364549,-9.255170283868836 487.2909698996656,-10.284945930663866 489.29765886287623,-11.28608144546854 491.304347826087,-12.258982357731128 493.31103678929765,-13.204075833962634 495.31772575250835,-14.121808474756335 497.32441471571906,-15.012644185873881 499.33110367892976,-15.87706212826376 501.33779264214047,-16.715554750949423 503.34448160535123,-17.528625909853673 505.3511705685619,-18.316789074817223 507.35785953177265,-19.080565626318617 509.3645484949833,-19.820483242716165 511.371237458194,-20.537074378208416 513.3779264214047,-21.23087483114577 515.3846153846155,-21.902422401821838 517.3913043478261,-22.552255638427596 519.3979933110368,-23.180912669461577 521.4046822742475,-23.788930120549765 523.4113712374582,-24.376842113344395 525.4180602006688,-24.9451793439257 527.4247491638796,-25.49446823793724 529.4314381270902,-26.025230179524357 531.438127090301,-26.537980811027268 533.4448160535117,-27.03322940029193 535.4515050167224,-27.511478272406094 537.4581939799331,-27.97322230263694 539.4648829431438,-28.418948467345047 541.4715719063545,-28.849135449661304 543.4782608695652,-29.26425329675368 545.4849498327759,-29.66476312555784 547.4916387959867,-30.05111687391468 549.4983277591973,-30.423757094133407 551.5050167224081,-30.783116786085913 553.5117056856188,-31.129619267034997 555.5183946488294,-31.46367807549808 557.5250836120401,-31.785696906556467 559.5317725752509,-32.096069576129 561.5384615384615,-32.39518001184095 563.5451505016722,-32.68340226823261 565.551839464883,-32.961100564165434 567.5585284280936,-33.22862934039637 569.5652173913044,-33.486333335403884 571.571906354515,-33.73454767765671 573.5785953177258,-33.97359799262699 575.5852842809364,-34.20380052295204 577.5919732441472,-34.42546226025115 579.5986622073578,-34.638881087203345 581.6053511705686,-34.84434592858477 583.6120401337793,-35.0421369100568 585.61872909699,-35.23252552358309 587.6254180602007,-35.41577479843525 589.6321070234114,-35.59213947682869 591.6387959866221,-35.76186619330227 593.6454849498327,-35.92519365702975 595.6521739130435,-36.0823528363164 597.6588628762543,-36.233567144597885 599.6655518394648,-36.379052627319794 601.6722408026756,-36.51901814913086 603.6789297658863,-36.65366558087641 605.685618729097,-36.783189985928686 607.6923076923076,-36.907779805435325 609.6989966555184,-37.0276170421113 611.705685618729,-37.142877442240575 613.7123745819398,-37.25373067558863 615.7190635451506,-37.36034051296417 617.7257525083612,-37.462865001198765 619.732441471572,-37.56145663534289 621.7391304347826,-37.65626252790548 623.7458193979934,-37.74742457498721 625.752508361204,-37.83507961918255 627.7591973244148,-37.91935960914603 629.7658862876254,-38.00039175573795 631.7725752508361,-38.07829868468221 633.7792642140469,-38.15319858568543 635.7859531772576,-38.225205357981 637.7926421404682,-38.294428752274996 639.7993311036789,-38.36097450908346 641.8060200668897,-38.42494449346114 643.8127090301003,-38.48643682613107 645.819397993311,-38.545546011033935 647.8260869565217,-38.602363059324176 649.8327759197324,-38.656975609845176 651.8394648829432,-38.70946804612436 653.8461538461538,-38.759921609932206 655.8528428093646,-38.808414511456135 657.8595317725752,-38.85502203614155 659.866220735786,-38.899816648259076 661.8729096989966,-38.94286809125768 663.8795986622074,-38.984243484966385 665.886287625418,-39.02400741971044 667.8929765886288,-39.06222204740811 669.8996655518395,-39.098947169716354 671.9063545150502,-39.13424032329462 673.9130434782608,-39.16815686225644 675.9197324414715,-39.200750037879175 677.9264214046823,-39.232071075642324 679.933110367893,-39.26216924966457 681.9397993311038,-39.29109195461021 683.9464882943143,-39.31888477513456 685.9531772575251,-39.34559155293735 687.9598662207359,-39.37125445149283 689.9665551839465,-39.39591401852471 691.9732441471572,-39.419609246292225 693.9799331103679,-39.44237762975351 695.9866220735786,-39.464255222670516 697.9933110367894,-39.48527669172017 700.0,-39.505475368673075" class="sigmoid-line"/>
<path d="M 100.0,260.0 102.0066889632107,260.0 104.01337792642141,260.0 106.02006688963212,260.0 108.02675585284283,260.0 110.03344481605353,260.0 112.04013377926418,260.0 114.04682274247489,260.0 116.0535117056856,260.0 118.0602006688963,260.0 120.066889632107,260.0 122.07357859531771,260.0 124.08026755852842,260.0 126.08695652173913,260.0 128.09364548494983,260.0 130.10033444816054,260.0 132.1070234113712,260.0 134.11371237458195,260.0 136.1204013377926,260.0 138.12709030100336,260.0 140.13377926421407,260.0 142.14046822742478,260.0 144.14715719063545,260.0 146.15384615384616,260.0 148.16053511705687,260.0 150.16722408026757,260.0 152.17391304347828,260.0 154.18060200668896,260.0 156.18729096989966,260.0 158.19397993311037,260.0 160.20066889632108,260.0 162.20735785953178,260.0 164.2140468227425,260.0 166.22073578595317,260.0 168.22742474916387,260.0 170.23411371237458,260.0 172.2408026755853,260.0 174.247491638796,260.0 176.25418060200667,260.0 178.26086956521738,260.0 180.26755852842808,260.0 182.2742474916388,260.0 184.2809364548495,260.0 186.2876254180602,260.0 188.29431438127094,260.0 190.3010033444816,260.0 192.30769230769232,260.0 194.314381270903,260.0 196.32107023411373,260.0 198.32775919732438,260.0 200.33444816053512,260.0 202.34113712374582,260.0 204.34782608695653,260.0 206.3545150501672,260.0 208.36120401337791,260.0 210.36789297658862,260.0 212.37458193979936,260.0 214.38127090301003,260.0 216.38795986622074,260.0 218.39464882943145,260.0 220.40133779264215,260.0 222.40802675585286,260.0 224.41471571906357,260.0 226.42140468227424,260.0 228.42809364548495,260.0 230.43478260869566,260.0 232.44147157190636,260.0 234.44816053511707,260.0 236.45484949832775,260.0 238.46153846153845,260.0 240.46822742474916,260.0 242.47491638795987,260.0 244.48160535117057,260.0 246.48829431438128,260.0 248.49498327759198,260.0 250.5016722408027,260.0 252.5083612040134,260.0 254.51505016722408,260.0 256.52173913043475,260.0 258.5284280936455,260.0 260.53511705685617,260.0 262.54180602006693,260.0 264.5484949832776,260.0 266.5551839464883,260.0 268.561872909699,260.0 270.5685618729097,260.0 272.5752508361204,260.0 274.5819397993311,260.0 276.5886287625418,260.0 278.5953177257525,260.0 280.60200668896323,260.0 282.60869565217394,260.0 284.61538461538464,260.0 286.6220735785953,260.0 288.62876254180605,260.0 290.6354515050167,260.0 292.6421404682274,260.0 294.6488294314381,260.0 296.6555183946488,260.0 298.66220735785953,260.0 300.66889632107024,260.0 302.67558528428094,260.0 304.68227424749165,260.0 306.68896321070235,260.0 308.695652173913,260.0 310.70234113712377,260.0 312.7090301003344,260.0 314.7157190635451,260.0 316.72240802675583,260.0 318.72909698996654,260.0 320.73578595317724,260.0 322.74247491638795,260.0 324.74916387959865,260.0 326.7558528428094,260.0 328.76254180602007,260.0 330.7692307692308,260.0 332.7759197324415,260.0 334.7826086956522,260.0 336.7892976588629,260.0 338.7959866220736,260.0 340.8026755852843,260.0 342.809364548495,260.0 344.8160535117057,260.0 346.8227424749164,260.0 348.82943143812713,260.0 350.8361204013378,260.0 352.8428093645485,260.0 354.8494983277592,260.0 356.8561872909699,260.0 358.8628762541806,260.0 360.8695652173913,260.0 362.876254180602,260.0 364.8829431438127,260.0 366.88963210702343,260.0 368.89632107023414,260.0 370.90301003344484,260.0 372.9096989966555,260.0 374.9163879598662,260.0 376.9230769230769,260.0 378.9297658862876,260.0 380.9364548494983,260.0 382.943143812709,260.0 384.94983277591973,260.0 386.95652173913044,260.0 388.96321070234114,260.0 390.96989966555185,260.0 392.97658862876256,260.0 394.98327759197326,260.0 396.98996655518397,260.0 398.9966555183947,260.0 401.0033444816054,259.1973244147157 403.0100334448161,257.59197324414714 405.0167224080268,255.9866220735786 407.0234113712375,254.38127090301003 409.03010033444815,252.77591973244145 411.03678929765886,251.1705685618729 413.04347826086956,249.56521739130434 415.05016722408027,247.95986622073576 417.056856187291,246.3545150501672 419.0635451505017,244.74916387959865 421.0702341137124,243.1438127090301 423.0769230769231,241.53846153846155 425.0836120401338,239.93311036789297 427.0903010033445,238.3277591973244 429.09698996655516,236.72240802675586 431.10367892976586,235.11705685618728 433.11036789297657,233.51170568561872 435.1170568561873,231.90635451505017 437.123745819398,230.30100334448161 439.1304347826087,228.69565217391306 441.1371237458194,227.09030100334448 443.1438127090301,225.48494983277592 445.1505016722408,223.87959866220737 447.1571906354515,222.2742474916388 449.1638795986622,220.66889632107024 451.17056856187287,219.06354515050168 453.17725752508363,217.45819397993307 455.18394648829434,215.85284280936452 457.19063545150505,214.24749163879596 459.19732441471575,212.6421404682274 461.20401337792646,211.03678929765886 463.21070234113716,209.43143812709027 465.21739130434787,207.82608695652172 467.2240802675585,206.22073578595317 469.2307692307693,204.61538461538458 471.23745819397993,203.01003344481603 473.24414715719064,201.40468227424748 475.25083612040135,199.79933110367892 477.25752508361205,198.19397993311037 479.26421404682276,196.5886287625418 481.27090301003346,194.98327759197323 483.27759197324417,193.37792642140468 485.2842809364549,191.7725752508361 487.2909698996656,190.16722408026754 489.29765886287623,188.561872909699 491.304347826087,186.95652173913044 493.31103678929765,185.35117056856188 495.31772575250835,183.7458193979933 497.32441471571906,182.14046822742475 499.33110367892976,180.5351170568562 501.33779264214047,178.9297658862876 503.34448160535123,177.32441471571903 505.3511705685619,175.7190635451505 507.35785953177265,174.1137123745819 509.3645484949833,172.5083612040134 511.371237458194,170.9030100334448 513.3779264214047,169.29765886287626 515.3846153846155,167.69230769230768 517.3913043478261,166.08695652173913 519.3979933110368,164.48160535117054 521.4046822742475,162.87625418060202 523.4113712374582,161.2709030100334 525.4180602006688,159.6655518394649 527.4247491638796,158.0602006688963 529.4314381270902,156.45484949832777 531.438127090301,154.8494983277592 533.4448160535117,153.24414715719064 535.4515050167224,151.63879598662206 537.4581939799331,150.03344481605353 539.4648829431438,148.42809364548492 541.4715719063545,146.82274247491642 543.4782608695652,145.2173913043478 545.4849498327759,143.6120401337793 547.4916387959867,142.0066889632107 549.4983277591973,140.4013377926421 551.5050167224081,138.79598662207357 553.5117056856188,137.190635451505 555.5183946488294,135.58528428093643 557.5250836120401,133.97993311036785 559.5317725752509,132.37458193979933 561.5384615384615,130.76923076923072 563.5451505016722,129.16387959866222 565.551839464883,127.55852842809361 567.5585284280936,125.95317725752508 569.5652173913044,124.3478260869565 571.571906354515,122.74247491638795 573.5785953177258,121.13712374581937 575.5852842809364,119.53177257525084 577.5919732441472,117.92642140468223 579.5986622073578,116.32107023411373 581.6053511705686,114.71571906354512 583.6120401337793,113.1103678929766 585.61872909699,111.50501672240802 587.6254180602007,109.89966555183946 589.6321070234114,108.29431438127088 591.6387959866221,106.68896321070235 593.6454849498327,105.08361204013374 595.6521739130435,103.47826086956525 597.6588628762543,101.87290969899664 599.6655518394648,100.26755852842811 601.6722408026756,98.66220735785953 603.6789297658863,97.05685618729098 605.685618729097,95.4515050167224 607.6923076923076,93.84615384615387 609.6989966555184,92.24080267558526 611.705685618729,90.63545150501676 613.7123745819398,89.03010033444815 615.7190635451506,87.42474916387954 617.7257525083612,85.81939799331104 619.732441471572,84.21404682274243 621.7391304347826,82.6086956521739 623.7458193979934,81.00334448160532 625.752508361204,79.39799331103677 627.7591973244148,77.79264214046819 629.7658862876254,76.18729096989966 631.7725752508361,74.58193979933105 633.7792642140469,72.97658862876256 635.7859531772576,71.37123745819395 637.7926421404682,69.76588628762542 639.7993311036789,68.16053511705684 641.8060200668897,66.55518394648828 643.8127090301003,64.9498327759197 645.819397993311,63.34448160535118 647.8260869565217,61.73913043478257 649.8327759197324,60.13377926421407 651.8394648829432,58.52842809364546 653.8461538461538,56.923076923076934 655.8528428093646,55.31772575250835 657.8595317725752,53.7123745819398 659.866220735786,52.107023411371216 661.8729096989966,50.50167224080269 663.8795986622074,48.89632107023408 665.886287625418,47.29096989966558 667.8929765886288,45.68561872909697 669.8996655518395,44.08026755852845 671.9063545150502,42.474916387959865 673.9130434782608,40.86956521739131 675.9197324414715,39.26421404682273 677.9264214046823,37.658862876254204 679.933110367893,36.053511705685594 681.9397993311038,34.44816053511701 683.9464882943143,32.842809364548486 685.9531772575251,31.237458193979876 687.9598662207359,29.63210702341138 689.9665551839465,28.02675585284277 691.9732441471572,26.421404682274243 693.9799331103679,24.81605351170566 695.9866220735786,23.210702341137107 697.9933110367894,21.605351170568525 700.0,20.0" class="relu-line"/>
<!-- Legend -->
<rect x="520" y="70" width="20" height="5" fill="#4285F4" />
<text x="615" y="78" class="label">Sigmoid (梯度易消失)</text>
<rect x="520" y="100" width="20" height="5" fill="#EA4335" />
<text x="600" y="108" class="label">ReLU (现代标准)</text>
</svg>
```