{"id":698,"date":"2020-08-14T08:39:35","date_gmt":"2020-08-14T08:39:35","guid":{"rendered":"http:\/\/lucylabs.gatech.edu\/ml4t\/project-3\/"},"modified":"2020-08-17T06:23:03","modified_gmt":"2020-08-17T06:23:03","slug":"project-3","status":"publish","type":"page","link":"https:\/\/lucylabs.gatech.edu\/ml4t\/code-documentation\/project-3\/","title":{"rendered":"Project 3"},"content":{"rendered":"<p>[et_pb_section fb_built=&#8221;1&#8243; _builder_version=&#8221;3.22&#8243;][et_pb_row _builder_version=&#8221;3.25&#8243; background_size=&#8221;initial&#8221; background_position=&#8221;top_left&#8221; background_repeat=&#8221;repeat&#8221;][et_pb_column type=&#8221;4_4&#8243; _builder_version=&#8221;3.25&#8243; custom_padding=&#8221;|||&#8221; custom_padding__hover=&#8221;|||&#8221;][et_pb_text _builder_version=&#8221;4.5.6&#8243; background_size=&#8221;initial&#8221; background_position=&#8221;top_left&#8221; background_repeat=&#8221;repeat&#8221; hover_enabled=&#8221;0&#8243;]<\/p>\n<div class=\"document\">\n<div class=\"documentwrapper\">\n<div class=\"bodywrapper\">\n<div class=\"body\" role=\"main\">\n<h1 style=\"text-align: center;\">Project 3: Assess Learners Documentation<\/h1>\n<p>&nbsp;<\/p>\n<h2><span style=\"text-decoration: underline;\">LinRegLearner.py<\/span><\/h2>\n<p>&nbsp;<\/p>\n<dl class=\"class\">\n<dt><em class=\"property\"><\/em><\/dt>\n<dt><em class=\"property\"><\/em><\/dt>\n<dt><em class=\"property\"><\/em><\/dt>\n<dt><em class=\"property\">class <\/em><code class=\"sig-prename descclassname\">LinRegLearner.<\/code><code class=\"sig-name descname\">LinRegLearner<\/code><span class=\"sig-paren\">(<\/span><em class=\"sig-param\">verbose=False<\/em><span class=\"sig-paren\">)<\/span><\/dt>\n<\/dl>\n<dl class=\"class\">\n<dd>\n<p>This is a Linear Regression Learner. It is implemented correctly.<\/p>\n<dl class=\"field-list simple\">\n<dt class=\"field-odd\">Parameters<\/dt>\n<dd class=\"field-odd\"><strong>verbose<\/strong> (<em>bool<\/em>) \u2013 If \u201cverbose\u201d is True, your code can print out information for debugging.<br \/> If verbose = False your code should not generate ANY output. When we test your code, verbose will be False.<\/dd>\n<\/dl>\n<dl class=\"method\">\n<dt id=\"LinRegLearner.LinRegLearner.add_evidence\"><code class=\"sig-name descname\">add_evidence<\/code><span class=\"sig-paren\">(<\/span><em class=\"sig-param\">data_x<\/em>, <em class=\"sig-param\">data_y<\/em><span class=\"sig-paren\">)<\/span><\/dt>\n<dd>\n<p>Add training data to learner<\/p>\n<dl class=\"field-list simple\">\n<dt class=\"field-odd\">Parameters<\/dt>\n<dd class=\"field-odd\">\n<ul class=\"simple\">\n<li><strong>data_x<\/strong> (<em>numpy.ndarray<\/em>) \u2013 A set of feature values used to train the learner<\/li>\n<li><strong>data_y<\/strong> (<em>numpy.ndarray<\/em>) \u2013 The value we are attempting to predict given the X data<\/li>\n<\/ul>\n<\/dd>\n<\/dl>\n<\/dd>\n<\/dl>\n<dl class=\"method\">\n<dt id=\"LinRegLearner.LinRegLearner.author\"><code class=\"sig-name descname\">author<\/code><span class=\"sig-paren\">(<\/span><span class=\"sig-paren\">)<\/span><\/dt>\n<dd>\n<dl class=\"field-list simple\">\n<dt class=\"field-odd\">Returns<\/dt>\n<dd class=\"field-odd\">\n<p>The GT username of the student<\/p>\n<\/dd>\n<dt class=\"field-even\">Return type<\/dt>\n<dd class=\"field-even\">\n<p>str<\/p>\n<\/dd>\n<\/dl>\n<\/dd>\n<\/dl>\n<dl class=\"method\">\n<dt id=\"LinRegLearner.LinRegLearner.query\"><code class=\"sig-name descname\">query<\/code><span class=\"sig-paren\">(<\/span><em class=\"sig-param\">points<\/em><span class=\"sig-paren\">)<\/span><\/dt>\n<dd>\n<p>Estimate a set of test points given the model we built.<\/p>\n<dl class=\"field-list simple\">\n<dt class=\"field-odd\">Parameters<\/dt>\n<dd class=\"field-odd\">\n<p><strong>points<\/strong> (<em>numpy.ndarray<\/em>) \u2013 A numpy array with each row corresponding to a specific query.<\/p>\n<\/dd>\n<dt class=\"field-even\">Returns<\/dt>\n<dd class=\"field-even\">\n<p>The predicted result of the input data according to the trained model<\/p>\n<\/dd>\n<dt class=\"field-odd\">Return type<\/dt>\n<dd class=\"field-odd\">\n<p>numpy.ndarray<\/p>\n<\/dd>\n<\/dl>\n<\/dd>\n<\/dl>\n<\/dd>\n<\/dl>\n<p><span class=\"target\" id=\"module-testlearner\"><\/span><\/p>\n<\/div>\n<\/div>\n<\/div>\n<\/div>\n<p><!-- \/divi:html --><\/p>\n<p><!-- divi:html --><\/p>\n<p class=\"clearer\"><!-- \/divi:html --><\/p>\n<p><!-- divi:html --><\/p>\n<p class=\"footer\">\u00a92020, ML4T Staff |\u00a0Powered by <a href=\"http:\/\/sphinx-doc.org\/\">Sphinx 2.2.0<\/a> &amp; <a href=\"https:\/\/github.com\/bitprophet\/alabaster\">Alabaster 0.7.12<\/a><\/p>\n<p><!-- \/divi:html --><\/p>\n<p>[\/et_pb_text][\/et_pb_column][\/et_pb_row][\/et_pb_section]<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Project 3: Assess Learners Documentation &nbsp; LinRegLearner.py &nbsp; class LinRegLearner.LinRegLearner(verbose=False) This is a Linear Regression Learner. It is implemented correctly. Parameters verbose (bool) \u2013 If \u201cverbose\u201d is True, your code can print out information for debugging. If verbose = False your code should not generate ANY output. When we test your code, verbose will be [&hellip;]<\/p>\n","protected":false},"author":2,"featured_media":0,"parent":683,"menu_order":2,"comment_status":"closed","ping_status":"closed","template":"","meta":{"_et_pb_use_builder":"on","_et_pb_old_content":"<!-- wp:html -->\n<meta charset=\"utf-8\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<title>Project 3: Assess Learners \u2014 ML4T 1.0 documentation<\/title>\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<link rel=\"stylesheet\" href=\"_static\/alabaster.css\" type=\"text\/css\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<link rel=\"stylesheet\" href=\"_static\/pygments.css\" type=\"text\/css\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<script type=\"text\/javascript\" id=\"documentation_options\" data-url_root=\".\/\" src=\"_static\/documentation_options.js\"><\/script>\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<script type=\"text\/javascript\" src=\"_static\/jquery.js\"><\/script>\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<script type=\"text\/javascript\" src=\"_static\/underscore.js\"><\/script>\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<script type=\"text\/javascript\" src=\"_static\/doctools.js\"><\/script>\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<script type=\"text\/javascript\" src=\"_static\/language_data.js\"><\/script>\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<link rel=\"index\" title=\"Index\" href=\"genindex.html\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<link rel=\"search\" title=\"Search\" href=\"search.html\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<link rel=\"next\" title=\"Project 4: Defeat Learners\" href=\"defeat_learners.html\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<link rel=\"prev\" title=\"Project 2: Optimize Something\" href=\"optimize_something.html\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<link rel=\"stylesheet\" href=\"_static\/custom.css\" type=\"text\/css\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<meta name=\"viewport\" content=\"width=device-width, initial-scale=0.9, maximum-scale=0.9\">\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<div class=\"document\">\n      <div class=\"documentwrapper\">\n        <div class=\"bodywrapper\">\n          \n\n          <div class=\"body\" role=\"main\">\n            \n  <div class=\"section\" id=\"module-LinRegLearner\">\n<span id=\"project-3-assess-learners\"><\/span><h1>Project 3: Assess Learners<a class=\"headerlink\" href=\"#module-LinRegLearner\" title=\"Permalink to this headline\">\u00b6<\/a><\/h1>\n<dl class=\"class\">\n<dt id=\"LinRegLearner.LinRegLearner\">\n<em class=\"property\">class <\/em><code class=\"sig-prename descclassname\">LinRegLearner.<\/code><code class=\"sig-name descname\">LinRegLearner<\/code><span class=\"sig-paren\">(<\/span><em class=\"sig-param\">verbose=False<\/em><span class=\"sig-paren\">)<\/span><a class=\"headerlink\" href=\"#LinRegLearner.LinRegLearner\" title=\"Permalink to this definition\">\u00b6<\/a><\/dt>\n<dd><p>This is a Linear Regression Learner. It is implemented correctly.<\/p>\n<dl class=\"field-list simple\">\n<dt class=\"field-odd\">Parameters<\/dt>\n<dd class=\"field-odd\"><p><strong>verbose<\/strong> (<em>bool<\/em>) \u2013 If \u201cverbose\u201d is True, your code can print out information for debugging.\nIf verbose = False your code should not generate ANY output. When we test your code, verbose will be False.<\/p>\n<\/dd>\n<\/dl>\n<dl class=\"method\">\n<dt id=\"LinRegLearner.LinRegLearner.add_evidence\">\n<code class=\"sig-name descname\">add_evidence<\/code><span class=\"sig-paren\">(<\/span><em class=\"sig-param\">data_x<\/em>, <em class=\"sig-param\">data_y<\/em><span class=\"sig-paren\">)<\/span><a class=\"headerlink\" href=\"#LinRegLearner.LinRegLearner.add_evidence\" title=\"Permalink to this definition\">\u00b6<\/a><\/dt>\n<dd><p>Add training data to learner<\/p>\n<dl class=\"field-list simple\">\n<dt class=\"field-odd\">Parameters<\/dt>\n<dd class=\"field-odd\"><ul class=\"simple\">\n<li><p><strong>data_x<\/strong> (<em>numpy.ndarray<\/em>) \u2013 A set of feature values used to train the learner<\/p><\/li>\n<li><p><strong>data_y<\/strong> (<em>numpy.ndarray<\/em>) \u2013 The value we are attempting to predict given the X data<\/p><\/li>\n<\/ul>\n<\/dd>\n<\/dl>\n<\/dd><\/dl>\n\n<dl class=\"method\">\n<dt id=\"LinRegLearner.LinRegLearner.author\">\n<code class=\"sig-name descname\">author<\/code><span class=\"sig-paren\">(<\/span><span class=\"sig-paren\">)<\/span><a class=\"headerlink\" href=\"#LinRegLearner.LinRegLearner.author\" title=\"Permalink to this definition\">\u00b6<\/a><\/dt>\n<dd><dl class=\"field-list simple\">\n<dt class=\"field-odd\">Returns<\/dt>\n<dd class=\"field-odd\"><p>The GT username of the student<\/p>\n<\/dd>\n<dt class=\"field-even\">Return type<\/dt>\n<dd class=\"field-even\"><p>str<\/p>\n<\/dd>\n<\/dl>\n<\/dd><\/dl>\n\n<dl class=\"method\">\n<dt id=\"LinRegLearner.LinRegLearner.query\">\n<code class=\"sig-name descname\">query<\/code><span class=\"sig-paren\">(<\/span><em class=\"sig-param\">points<\/em><span class=\"sig-paren\">)<\/span><a class=\"headerlink\" href=\"#LinRegLearner.LinRegLearner.query\" title=\"Permalink to this definition\">\u00b6<\/a><\/dt>\n<dd><p>Estimate a set of test points given the model we built.<\/p>\n<dl class=\"field-list simple\">\n<dt class=\"field-odd\">Parameters<\/dt>\n<dd class=\"field-odd\"><p><strong>points<\/strong> (<em>numpy.ndarray<\/em>) \u2013 A numpy array with each row corresponding to a specific query.<\/p>\n<\/dd>\n<dt class=\"field-even\">Returns<\/dt>\n<dd class=\"field-even\"><p>The predicted result of the input data according to the trained model<\/p>\n<\/dd>\n<dt class=\"field-odd\">Return type<\/dt>\n<dd class=\"field-odd\"><p>numpy.ndarray<\/p>\n<\/dd>\n<\/dl>\n<\/dd><\/dl>\n\n<\/dd><\/dl>\n\n<span class=\"target\" id=\"module-testlearner\"><\/span><\/div>\n\n\n          <\/div>\n          \n        <\/div>\n      <\/div>\n\n\n\n\n\n\n\n\n        <\/div>\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<div class=\"clearer\"><\/div>\n<!-- \/wp:html -->\n\n<!-- wp:html -->\n<div class=\"footer\">\n      \u00a92020, ML4T Staff.\n      \n      |\n      Powered by <a href=\"http:\/\/sphinx-doc.org\/\">Sphinx 2.2.0<\/a>\n      &amp; <a href=\"https:\/\/github.com\/bitprophet\/alabaster\">Alabaster 0.7.12<\/a>\n      \n\n    <\/div>\n<!-- \/wp:html -->","_et_gb_content_width":"","footnotes":""},"class_list":["post-698","page","type-page","status-publish","hentry"],"jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/pages\/698","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/pages"}],"about":[{"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/types\/page"}],"author":[{"embeddable":true,"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/users\/2"}],"replies":[{"embeddable":true,"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/comments?post=698"}],"version-history":[{"count":7,"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/pages\/698\/revisions"}],"predecessor-version":[{"id":787,"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/pages\/698\/revisions\/787"}],"up":[{"embeddable":true,"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/pages\/683"}],"wp:attachment":[{"href":"https:\/\/lucylabs.gatech.edu\/ml4t\/wp-json\/wp\/v2\/media?parent=698"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}