What activation function should I use for a specific regression problem?How flexible is the link between objective function and output layer activation function?Technology stack for linear regression on (not so) large datasetParameterization regression of rotation angleAlternatives to linear activation function in regression tasks to limit the outputWhat is the Time Complexity of Linear Regression?Activation function vs Squashing functionUsing Keras to Predict a Function Following a Normal Distributionbest activation function for ensemble?Regression with -1,1 target range - Should we use a tanh activation in the last 1 unit dense layer?Images Score Regression only regresses to the average of the target values

Doesn't the system of the Supreme Court oppose justice?

How can I write humor as character trait?

Is there a RAID 0 Equivalent for RAM?

I found an audio circuit and I built it just fine, but I find it a bit too quiet. How do I amplify the output so that it is a bit louder?

What is Cash Advance APR?

Is this part of the description of the Archfey warlock's Misty Escape feature redundant?

Circuit Analysis: Obtaining Close Loop OP - AMP Transfer function

Change the color of a single dot in `ddot` symbol

When were female captains banned from Starfleet?

US tourist/student visa

What is the difference between lands and mana?

What (the heck) is a Super Worm Equinox Moon?

Microchip documentation does not label CAN buss pins on micro controller pinout diagram

A variation to the phrase "hanging over my shoulders"

What does Apple's new App Store requirement mean

What are some good ways to treat frozen vegetables such that they behave like fresh vegetables when stir frying them?

A Trivial Diagnosis

How to convince somebody that he is fit for something else, but not this job?

Is there any evidence that Cleopatra and Caesarion considered fleeing to India to escape the Romans?

Will number of steps recorded on FitBit/any fitness tracker add up distance in PokemonGo?

What is the English pronunciation of "pain au chocolat"?

Permission on Database

Does the reader need to like the PoV character?

Shouldn’t conservatives embrace universal basic income?



What activation function should I use for a specific regression problem?


How flexible is the link between objective function and output layer activation function?Technology stack for linear regression on (not so) large datasetParameterization regression of rotation angleAlternatives to linear activation function in regression tasks to limit the outputWhat is the Time Complexity of Linear Regression?Activation function vs Squashing functionUsing Keras to Predict a Function Following a Normal Distributionbest activation function for ensemble?Regression with -1,1 target range - Should we use a tanh activation in the last 1 unit dense layer?Images Score Regression only regresses to the average of the target values













1












$begingroup$


Which is better for regression problems create a neural net with tanh/sigmoid and exp(like) activations or ReLU and linear? Standard is to use ReLU but it's brute force solution that requires certain net size and I would like to avoid creating a very big net, also sigmoid is much more prefered but in my case regression will output values from range (0, 1e7)... maybe also sigmoid net with linear head will work? I am curious about your take on the subject.










share|improve this question











$endgroup$
















    1












    $begingroup$


    Which is better for regression problems create a neural net with tanh/sigmoid and exp(like) activations or ReLU and linear? Standard is to use ReLU but it's brute force solution that requires certain net size and I would like to avoid creating a very big net, also sigmoid is much more prefered but in my case regression will output values from range (0, 1e7)... maybe also sigmoid net with linear head will work? I am curious about your take on the subject.










    share|improve this question











    $endgroup$














      1












      1








      1





      $begingroup$


      Which is better for regression problems create a neural net with tanh/sigmoid and exp(like) activations or ReLU and linear? Standard is to use ReLU but it's brute force solution that requires certain net size and I would like to avoid creating a very big net, also sigmoid is much more prefered but in my case regression will output values from range (0, 1e7)... maybe also sigmoid net with linear head will work? I am curious about your take on the subject.










      share|improve this question











      $endgroup$




      Which is better for regression problems create a neural net with tanh/sigmoid and exp(like) activations or ReLU and linear? Standard is to use ReLU but it's brute force solution that requires certain net size and I would like to avoid creating a very big net, also sigmoid is much more prefered but in my case regression will output values from range (0, 1e7)... maybe also sigmoid net with linear head will work? I am curious about your take on the subject.







      machine-learning neural-network deep-learning regression activation-function






      share|improve this question















      share|improve this question













      share|improve this question




      share|improve this question








      edited 1 hour ago









      Media

      7,36762161




      7,36762161










      asked 4 hours ago









      questerquester

      313




      313




















          2 Answers
          2






          active

          oldest

          votes


















          1












          $begingroup$

          The issue with sigmoid and tanh activations is that their gradients saturate for extreme values of their arguments. This may occur if you do not normalize your inputs. If the learned weights of the unit are such that the gradient of its activation is close to zero, it will take longer for any updates to be reflected in the unit's weights. A final layer with no non-linearity will help you scale up your hidden layers' outputs.



          In the end, the performance is application specific. You should try out both kinds of activations on a subset of your data and see which performs better.



          Credit: https://medium.com/@krishnakalyan3/introduction-to-exponential-linear-unit-d3e2904b366c






          share|improve this answer









          $endgroup$




















            0












            $begingroup$

            There are two points that have to be considered.



            1. Take care of the output of your network. If that's a Real number and can take any value, you have to use linear activation as the output.

            2. The inner activations highly depend on your task and the size of the network that you use. What I'm going to tell you is based on experience. If you don't have a very deep network, $tanh$ and $ReLU$ may not differ very much in convergence time. If you're using very deep networks, don't use $tahn$ at all. $ReLU$ is also not recommended in some contexts. You can employ $PReLU$ in very deep networks. It does not add too many parameters to learn. You can also use $leaky-ReLU$ in order to avoid dying ReLU problem which may occur.

            Finally, about the other nonlinearity that you've referred; try not to use $Sigmoid$ due to that fact that it's expected value is not equal to zero but half. It's a bit statistical stuff, but you can consider it's roughly hard for a network to learn shifted weights.






            share|improve this answer











            $endgroup$












              Your Answer





              StackExchange.ifUsing("editor", function ()
              return StackExchange.using("mathjaxEditing", function ()
              StackExchange.MarkdownEditor.creationCallbacks.add(function (editor, postfix)
              StackExchange.mathjaxEditing.prepareWmdForMathJax(editor, postfix, [["$", "$"], ["\\(","\\)"]]);
              );
              );
              , "mathjax-editing");

              StackExchange.ready(function()
              var channelOptions =
              tags: "".split(" "),
              id: "557"
              ;
              initTagRenderer("".split(" "), "".split(" "), channelOptions);

              StackExchange.using("externalEditor", function()
              // Have to fire editor after snippets, if snippets enabled
              if (StackExchange.settings.snippets.snippetsEnabled)
              StackExchange.using("snippets", function()
              createEditor();
              );

              else
              createEditor();

              );

              function createEditor()
              StackExchange.prepareEditor(
              heartbeatType: 'answer',
              autoActivateHeartbeat: false,
              convertImagesToLinks: false,
              noModals: true,
              showLowRepImageUploadWarning: true,
              reputationToPostImages: null,
              bindNavPrevention: true,
              postfix: "",
              imageUploader:
              brandingHtml: "Powered by u003ca class="icon-imgur-white" href="https://imgur.com/"u003eu003c/au003e",
              contentPolicyHtml: "User contributions licensed under u003ca href="https://creativecommons.org/licenses/by-sa/3.0/"u003ecc by-sa 3.0 with attribution requiredu003c/au003e u003ca href="https://stackoverflow.com/legal/content-policy"u003e(content policy)u003c/au003e",
              allowUrls: true
              ,
              onDemand: true,
              discardSelector: ".discard-answer"
              ,immediatelyShowMarkdownHelp:true
              );



              );













              draft saved

              draft discarded


















              StackExchange.ready(
              function ()
              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdatascience.stackexchange.com%2fquestions%2f47751%2fwhat-activation-function-should-i-use-for-a-specific-regression-problem%23new-answer', 'question_page');

              );

              Post as a guest















              Required, but never shown

























              2 Answers
              2






              active

              oldest

              votes








              2 Answers
              2






              active

              oldest

              votes









              active

              oldest

              votes






              active

              oldest

              votes









              1












              $begingroup$

              The issue with sigmoid and tanh activations is that their gradients saturate for extreme values of their arguments. This may occur if you do not normalize your inputs. If the learned weights of the unit are such that the gradient of its activation is close to zero, it will take longer for any updates to be reflected in the unit's weights. A final layer with no non-linearity will help you scale up your hidden layers' outputs.



              In the end, the performance is application specific. You should try out both kinds of activations on a subset of your data and see which performs better.



              Credit: https://medium.com/@krishnakalyan3/introduction-to-exponential-linear-unit-d3e2904b366c






              share|improve this answer









              $endgroup$

















                1












                $begingroup$

                The issue with sigmoid and tanh activations is that their gradients saturate for extreme values of their arguments. This may occur if you do not normalize your inputs. If the learned weights of the unit are such that the gradient of its activation is close to zero, it will take longer for any updates to be reflected in the unit's weights. A final layer with no non-linearity will help you scale up your hidden layers' outputs.



                In the end, the performance is application specific. You should try out both kinds of activations on a subset of your data and see which performs better.



                Credit: https://medium.com/@krishnakalyan3/introduction-to-exponential-linear-unit-d3e2904b366c






                share|improve this answer









                $endgroup$















                  1












                  1








                  1





                  $begingroup$

                  The issue with sigmoid and tanh activations is that their gradients saturate for extreme values of their arguments. This may occur if you do not normalize your inputs. If the learned weights of the unit are such that the gradient of its activation is close to zero, it will take longer for any updates to be reflected in the unit's weights. A final layer with no non-linearity will help you scale up your hidden layers' outputs.



                  In the end, the performance is application specific. You should try out both kinds of activations on a subset of your data and see which performs better.



                  Credit: https://medium.com/@krishnakalyan3/introduction-to-exponential-linear-unit-d3e2904b366c






                  share|improve this answer









                  $endgroup$



                  The issue with sigmoid and tanh activations is that their gradients saturate for extreme values of their arguments. This may occur if you do not normalize your inputs. If the learned weights of the unit are such that the gradient of its activation is close to zero, it will take longer for any updates to be reflected in the unit's weights. A final layer with no non-linearity will help you scale up your hidden layers' outputs.



                  In the end, the performance is application specific. You should try out both kinds of activations on a subset of your data and see which performs better.



                  Credit: https://medium.com/@krishnakalyan3/introduction-to-exponential-linear-unit-d3e2904b366c







                  share|improve this answer












                  share|improve this answer



                  share|improve this answer










                  answered 4 hours ago









                  hazrmardhazrmard

                  1264




                  1264





















                      0












                      $begingroup$

                      There are two points that have to be considered.



                      1. Take care of the output of your network. If that's a Real number and can take any value, you have to use linear activation as the output.

                      2. The inner activations highly depend on your task and the size of the network that you use. What I'm going to tell you is based on experience. If you don't have a very deep network, $tanh$ and $ReLU$ may not differ very much in convergence time. If you're using very deep networks, don't use $tahn$ at all. $ReLU$ is also not recommended in some contexts. You can employ $PReLU$ in very deep networks. It does not add too many parameters to learn. You can also use $leaky-ReLU$ in order to avoid dying ReLU problem which may occur.

                      Finally, about the other nonlinearity that you've referred; try not to use $Sigmoid$ due to that fact that it's expected value is not equal to zero but half. It's a bit statistical stuff, but you can consider it's roughly hard for a network to learn shifted weights.






                      share|improve this answer











                      $endgroup$

















                        0












                        $begingroup$

                        There are two points that have to be considered.



                        1. Take care of the output of your network. If that's a Real number and can take any value, you have to use linear activation as the output.

                        2. The inner activations highly depend on your task and the size of the network that you use. What I'm going to tell you is based on experience. If you don't have a very deep network, $tanh$ and $ReLU$ may not differ very much in convergence time. If you're using very deep networks, don't use $tahn$ at all. $ReLU$ is also not recommended in some contexts. You can employ $PReLU$ in very deep networks. It does not add too many parameters to learn. You can also use $leaky-ReLU$ in order to avoid dying ReLU problem which may occur.

                        Finally, about the other nonlinearity that you've referred; try not to use $Sigmoid$ due to that fact that it's expected value is not equal to zero but half. It's a bit statistical stuff, but you can consider it's roughly hard for a network to learn shifted weights.






                        share|improve this answer











                        $endgroup$















                          0












                          0








                          0





                          $begingroup$

                          There are two points that have to be considered.



                          1. Take care of the output of your network. If that's a Real number and can take any value, you have to use linear activation as the output.

                          2. The inner activations highly depend on your task and the size of the network that you use. What I'm going to tell you is based on experience. If you don't have a very deep network, $tanh$ and $ReLU$ may not differ very much in convergence time. If you're using very deep networks, don't use $tahn$ at all. $ReLU$ is also not recommended in some contexts. You can employ $PReLU$ in very deep networks. It does not add too many parameters to learn. You can also use $leaky-ReLU$ in order to avoid dying ReLU problem which may occur.

                          Finally, about the other nonlinearity that you've referred; try not to use $Sigmoid$ due to that fact that it's expected value is not equal to zero but half. It's a bit statistical stuff, but you can consider it's roughly hard for a network to learn shifted weights.






                          share|improve this answer











                          $endgroup$



                          There are two points that have to be considered.



                          1. Take care of the output of your network. If that's a Real number and can take any value, you have to use linear activation as the output.

                          2. The inner activations highly depend on your task and the size of the network that you use. What I'm going to tell you is based on experience. If you don't have a very deep network, $tanh$ and $ReLU$ may not differ very much in convergence time. If you're using very deep networks, don't use $tahn$ at all. $ReLU$ is also not recommended in some contexts. You can employ $PReLU$ in very deep networks. It does not add too many parameters to learn. You can also use $leaky-ReLU$ in order to avoid dying ReLU problem which may occur.

                          Finally, about the other nonlinearity that you've referred; try not to use $Sigmoid$ due to that fact that it's expected value is not equal to zero but half. It's a bit statistical stuff, but you can consider it's roughly hard for a network to learn shifted weights.







                          share|improve this answer














                          share|improve this answer



                          share|improve this answer








                          edited 1 hour ago

























                          answered 1 hour ago









                          MediaMedia

                          7,36762161




                          7,36762161



























                              draft saved

                              draft discarded
















































                              Thanks for contributing an answer to Data Science Stack Exchange!


                              • Please be sure to answer the question. Provide details and share your research!

                              But avoid


                              • Asking for help, clarification, or responding to other answers.

                              • Making statements based on opinion; back them up with references or personal experience.

                              Use MathJax to format equations. MathJax reference.


                              To learn more, see our tips on writing great answers.




                              draft saved


                              draft discarded














                              StackExchange.ready(
                              function ()
                              StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2fdatascience.stackexchange.com%2fquestions%2f47751%2fwhat-activation-function-should-i-use-for-a-specific-regression-problem%23new-answer', 'question_page');

                              );

                              Post as a guest















                              Required, but never shown





















































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown

































                              Required, but never shown














                              Required, but never shown












                              Required, but never shown







                              Required, but never shown







                              Popular posts from this blog

                              Ружовы пелікан Змест Знешні выгляд | Пашырэнне | Асаблівасці біялогіі | Літаратура | НавігацыяДагледжаная версіяправерана1 зменаДагледжаная версіяправерана1 змена/ 22697590 Сістэматыкана ВіківідахВыявына Вікісховішчы174693363011049382

                              ValueError: Error when checking input: expected conv2d_13_input to have shape (3, 150, 150) but got array with shape (150, 150, 3)2019 Community Moderator ElectionError when checking : expected dense_1_input to have shape (None, 5) but got array with shape (200, 1)Error 'Expected 2D array, got 1D array instead:'ValueError: Error when checking input: expected lstm_41_input to have 3 dimensions, but got array with shape (40000,100)ValueError: Error when checking target: expected dense_1 to have shape (7,) but got array with shape (1,)ValueError: Error when checking target: expected dense_2 to have shape (1,) but got array with shape (0,)Keras exception: ValueError: Error when checking input: expected conv2d_1_input to have shape (150, 150, 3) but got array with shape (256, 256, 3)Steps taking too long to completewhen checking input: expected dense_1_input to have shape (13328,) but got array with shape (317,)ValueError: Error when checking target: expected dense_3 to have shape (None, 1) but got array with shape (7715, 40000)Keras exception: Error when checking input: expected dense_input to have shape (2,) but got array with shape (1,)

                              Illegal assignment from SObject to ContactFetching String, Id from Map - Illegal Assignment Id to Field / ObjectError: Compile Error: Illegal assignment from String to BooleanError: List has no rows for assignment to SObjectError on Test Class - System.QueryException: List has no rows for assignment to SObjectRemote action problemDML requires SObject or SObject list type error“Illegal assignment from List to List”Test Class Fail: Batch Class: System.QueryException: List has no rows for assignment to SObjectMapping to a user'List has no rows for assignment to SObject' Mystery