Non-linear regression with wide spread of datapoints

username: Shilpa
cooked: <p>Hi Guys,<br>
I have a non linear dataset with around 25 features and 2 target variables to be predicted. The data points have a wide spread. It is a regression problem. The attached image shows the non-linear distribution of the data which shows how the data is dispersed (Target1 vs each feature).</p>
<p>I have 2 questions:</p>
<ol>
<li>
<p>I want to know if CNN networks with non-linear activation layers can be used to predict multiple target variables in such non-linear patterns?</p>
</li>
<li>
<p>Do I need to use any specific CNN architecture (encoder-decoder may be) to handle non-linear regression with dispersed pattern as in the pairplot image?</p>
</li>
</ol>
<p><div class="lightbox-wrapper"><a class="lightbox" href="https://discuss.pytorch.org/uploads/default/original/3X/0/7/07e94a4ad4c3f83f77aa4025ee78658ffeb0ea9b.jpeg" data-download-href="https://discuss.pytorch.org/uploads/default/07e94a4ad4c3f83f77aa4025ee78658ffeb0ea9b" title="distribution - features vs target"><img src="https://discuss.pytorch.org/uploads/default/optimized/3X/0/7/07e94a4ad4c3f83f77aa4025ee78658ffeb0ea9b_2_690x45.jpeg" alt="distribution - features vs target" data-base62-sha1="17ZabnyzYNqduWw76DMorTM5COL" width="690" height="45" srcset="https://discuss.pytorch.org/uploads/default/optimized/3X/0/7/07e94a4ad4c3f83f77aa4025ee78658ffeb0ea9b_2_690x45.jpeg, https://discuss.pytorch.org/uploads/default/optimized/3X/0/7/07e94a4ad4c3f83f77aa4025ee78658ffeb0ea9b_2_1035x67.jpeg 1.5x, https://discuss.pytorch.org/uploads/default/optimized/3X/0/7/07e94a4ad4c3f83f77aa4025ee78658ffeb0ea9b_2_1380x90.jpeg 2x" data-dominant-color="C7DBE9"><div class="meta"><svg class="fa d-icon d-icon-far-image svg-icon" aria-hidden="true"><use href="#far-image"></use></svg><span class="filename">distribution - features vs target</span><span class="informations">1387×91 42.3 KB</span><svg class="fa d-icon d-icon-discourse-expand svg-icon" aria-hidden="true"><use href="#discourse-expand"></use></svg></div></a></div></p>

username: scollazo
cooked: <p>Hi Shilpa! I am running into a problem with non-linear regression and I would like to know if you get a solution for this problem you posted some months ago. Could you manage to solve this problem?</p>

username: Shilpa
cooked: <aside class="quote no-group" data-username="Shilpa" data-post="1" data-topic="124155">
<div class="title">
<div class="quote-controls"></div>
<img loading="lazy" alt="" width="24" height="24" src="https://discuss.pytorch.org/user_avatar/discuss.pytorch.org/shilpa/48/39352_2.png" class="avatar"> Shilpa:</div>
<blockquote>
<p>if CNN networks with non-linear activation layers can be used to predict multiple target variables in such non-linear patterns?</p>
</blockquote>
</aside>
<p>Hi Santiago,<br>
I tried both a sequential network and a CNN network. The sequential network worked better in my case. CNN did not reduce loss beyond a point even after multiple hyper-parameter adjustments. What is the error/issue that you are facing?</p>

username: scollazo
cooked: <p>Hi Shilpa, thanks for the answer!<br>
Okay, is good to know that the sequential network worked better than the CNN. My problem is different from yours, I think. I explained it in the following link <a href="https://discuss.pytorch.org/t/getting-a-zero-grad-in-non-linear-regression/140005">https://discuss.pytorch.org/t/getting-a-zero-grad-in-non-linear-regression/140005</a></p>

username: Shilpa
cooked: <p>Hi Santiago,</p>
<p>Check this blog, if it helps.</p><aside class="onebox allowlistedgeneric" data-onebox-src="https://medium.com/@benjamin.phillips22/simple-regression-with-neural-networks-in-pytorch-313f06910379">
  <header class="source">

      <a href="https://medium.com/@benjamin.phillips22/simple-regression-with-neural-networks-in-pytorch-313f06910379" target="_blank" rel="noopener nofollow ugc" title="04:28AM - 15 December 2018">Medium – 15 Dec 18</a>
  </header>

  <article class="onebox-body">
    <div class="aspect-image" style="--aspect-ratio:690/276;"><img src="https://miro.medium.com/max/720/1*dDL9XWeWVXuA_eK2daNOaQ.png" class="thumbnail" width="690" height="276"></div>

<h3><a href="https://medium.com/@benjamin.phillips22/simple-regression-with-neural-networks-in-pytorch-313f06910379" target="_blank" rel="noopener nofollow ugc">Simple Regression with Neural Networks in PyTorch</a></h3>

  <p>Neural networks are sometimes described as a ‘universal function approximator’. Here I show a few examples of simple and slightly more…</p>

  <p>
    <span class="label1">Reading time: 2 min read</span>
  </p>

  </article>

  <div class="onebox-metadata">
    
    
  </div>

  <div style="clear: both"></div>
</aside>

<p>In your other post, what is happening in the “class” function? Can you try with a sequential network with multiple hidden layers with non-linear activations?</p>

username: scollazo
cooked: <p>Hi Shilpa,<br>
Thank you for the post you shared! I answered your questions in the other post.</p>