ICP7 - GeoSnipes/Big-Data GitHub Wiki

Sub-Team Members

5-2 15 Naga Venkata Satya Pranoop Mutha

5-2 23 Geovanni West


ICP 7

Objective: Implement Linear Regression for the given data

trX = np.linespace(0,10,100) trY = 4*trX + 6 and report its

  • a. Training Cost
  • b. Testing Cost and
  • c. Absolute Mean Square Loss Difference.

Tensor Flow

Tensor Flow was originally developed by the Google Brain Team with Google's Machine Intelligence Research organization for the purposes of conducting machine learning and deep neural networks research, but the system is general enough to be applicable in a wide variety of domains as well.

Tensor flow programs are usually structured into a construction phase, that assembles a graph, and an execution phase that uses a session to execute ops in the graph.

The TensorFlow Python library has a default graph to which ops constructors add nodes. It relies on highly efficient C++ backend to do its computation which is called a session.

Training and Testing Cost Calculation

Mean Squared Error Calculation

Tensor Flow Output Without Noise:

Output 1:

Output 2:

Tensor Flow Output With Noise:

Summary:

We found a couple of observations from the above outputs:

  1. Comparing the output 1 and output 2, we can see that, for the same input, the training cost, testing cost and the mean squared error has changed. This is because, if we observe the training input, linspace command generates 100 random points in the interval from 0 to 10. So, each time when we run the code, it generates different data points. So, for a different set of data points, the training cost,testing cost and mean squared error has been changed.

  2. When we added noise, the values have been changed.

Click here for Source Code

⚠️ **GitHub.com Fallback** ⚠️