{"action":"created","comment":{"url":"https://api.github.com/repos/esa/pagmo2/pulls/comments/99412041","pull_request_review_id":20092267,"id":99412041,"diff_hunk":"@@ -0,0 +1,1218 @@\n+/* Copyright 2017 PaGMO development team\n+\n+This file is part of the PaGMO library.\n+\n+The PaGMO library is free software; you can redistribute it and/or modify\n+it under the terms of either:\n+\n+  * the GNU Lesser General Public License as published by the Free\n+    Software Foundation; either version 3 of the License, or (at your\n+    option) any later version.\n+\n+or\n+\n+  * the GNU General Public License as published by the Free Software\n+    Foundation; either version 3 of the License, or (at your option) any\n+    later version.\n+\n+or both in parallel, as here.\n+\n+The PaGMO library is distributed in the hope that it will be useful, but\n+WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY\n+or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License\n+for more details.\n+\n+You should have received copies of the GNU General Public License and the\n+GNU Lesser General Public License along with the PaGMO library.  If not,\n+see https://www.gnu.org/licenses/. */\n+\n+#ifndef PAGMO_PROBLEM_CEC2013_HPP\n+#define PAGMO_PROBLEM_CEC2013_HPP\n+\n+#include <exception>\n+#include <fstream>\n+#include <iostream>\n+#include <string>\n+#include <utility>\n+#include <vector>\n+\n+#include \"../detail/constants.hpp\"\n+#include \"../exceptions.hpp\"\n+#include \"../problem.hpp\" // needed for cereal registration macro\n+#include \"../types.hpp\"\n+\n+#define INF 1.0e99\n+#define E 2.7182818284590452353602874713526625\n+\n+namespace pagmo\n+{\n+/// The CEC 2013 problems: Real-Parameter Single Objective Optimization Competition\n+/**\n+ *\n+ * \\image html cec2013.png\n+ *\n+ * The 28 problems of the competition on real-parameter single objective optimization problems that\n+ * was organized for the 2013 IEEE Congress on Evolutionary Computation.\n+ *\n+ * **NOTE**: This set of UDAs require the data files that can be downloaded from the link below.\n+ * Upon construction, it expects to find two files named \"M_Dx.txt\" and \"shift_data.txt\" (where \"x\" is\n+ * the problem dimension) in the directory \\p dir\n+ *\n+ * NOTE All problems are box-bounded, continuous, single objective problems.\n+ *\n+ * @see http://www.ntu.edu.sg/home/EPNSugan/index_files/CEC2013/CEC2013.htm\n+ * @see http://web.mysites.ntu.edu.sg/epnsugan/PublicSite/Shared%20Documents/CEC2013/cec13-c-code.zip\n+ */\n+class cec2013\n+{\n+public:\n+    /// Default Constructor\n+    /**\n+     * Will construct an empty object\n+     *\n+     * **NOTE** This constructor should never be used and is here only for serialization\n+     */\n+    cec2013() : m_prob_id(1), m_rotation_matrix(), m_origin_shift(), m_y(2), m_z(2) {}\n+    /// Constructor\n+    /**\n+     * Will construct one of the 28 CEC2013 problems\n+     *\n+     * @param[in] prob_id The problem id. One of [1,2,...,28]\n+     * @param[in] dim problem dimension. One of [2,5,10,20,30,...,100]\n+     * @param[in] data_dir The path where the CEC2013 data files are located.\n+     *\n+     * **NOTE** Two files are expected to be in \\p dir \"M_Dx.txt\" and \"shift_data.txt\", where \"x\" is\n+     * the problem dimension \\p dim\n+     *\n+     * @see http://web.mysites.ntu.edu.sg/epnsugan/PublicSite/Shared%20Documents/CEC2013/cec13-c-code.zip to find\n+     * the files\n+     *\n+     * @throws invalid_argument if \\p prob_id is not in [1,18] or if \\p dim is not one of\n+     * [2,5,10,20,30,40,50,60,70,80,90,100]\n+     * @throws io_error if the files are not found","path":"include/pagmo/problems/cec2013.hpp","position":92,"original_position":92,"commit_id":"09fa2887dd22e0e51881a75ab4b3cb365b6b2dd2","original_commit_id":"09fa2887dd22e0e51881a75ab4b3cb365b6b2dd2","user":{"login":"bluescarni","id":623038,"avatar_url":"https://avatars.githubusercontent.com/u/623038?v=3","gravatar_id":"","url":"https://api.github.com/users/bluescarni","html_url":"https://github.com/bluescarni","followers_url":"https://api.github.com/users/bluescarni/followers","following_url":"https://api.github.com/users/bluescarni/following{/other_user}","gists_url":"https://api.github.com/users/bluescarni/gists{/gist_id}","starred_url":"https://api.github.com/users/bluescarni/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bluescarni/subscriptions","organizations_url":"https://api.github.com/users/bluescarni/orgs","repos_url":"https://api.github.com/users/bluescarni/repos","events_url":"https://api.github.com/users/bluescarni/events{/privacy}","received_events_url":"https://api.github.com/users/bluescarni/received_events","type":"User","site_admin":false},"body":"Shouldn't the exception here be ``std::ios_base::failure``?","created_at":"2017-02-03T20:01:18Z","updated_at":"2017-02-03T20:10:33Z","html_url":"https://github.com/esa/pagmo2/pull/13#discussion_r99412041","pull_request_url":"https://api.github.com/repos/esa/pagmo2/pulls/13","_links":{"self":{"href":"https://api.github.com/repos/esa/pagmo2/pulls/comments/99412041"},"html":{"href":"https://github.com/esa/pagmo2/pull/13#discussion_r99412041"},"pull_request":{"href":"https://api.github.com/repos/esa/pagmo2/pulls/13"}}},"pull_request":{"url":"https://api.github.com/repos/esa/pagmo2/pulls/13","id":104562989,"html_url":"https://github.com/esa/pagmo2/pull/13","diff_url":"https://github.com/esa/pagmo2/pull/13.diff","patch_url":"https://github.com/esa/pagmo2/pull/13.patch","issue_url":"https://api.github.com/repos/esa/pagmo2/issues/13","number":13,"state":"open","locked":false,"title":"The CEC2013 problems","user":{"login":"darioizzo","id":3327087,"avatar_url":"https://avatars.githubusercontent.com/u/3327087?v=3","gravatar_id":"","url":"https://api.github.com/users/darioizzo","html_url":"https://github.com/darioizzo","followers_url":"https://api.github.com/users/darioizzo/followers","following_url":"https://api.github.com/users/darioizzo/following{/other_user}","gists_url":"https://api.github.com/users/darioizzo/gists{/gist_id}","starred_url":"https://api.github.com/users/darioizzo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darioizzo/subscriptions","organizations_url":"https://api.github.com/users/darioizzo/orgs","repos_url":"https://api.github.com/users/darioizzo/repos","events_url":"https://api.github.com/users/darioizzo/events{/privacy}","received_events_url":"https://api.github.com/users/darioizzo/received_events","type":"User","site_admin":false},"body":"","created_at":"2017-02-03T16:11:40Z","updated_at":"2017-02-03T20:10:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"8b5cfd2ba77d07cd3285b625184d87a0e8c1b3d8","assignee":{"login":"darioizzo","id":3327087,"avatar_url":"https://avatars.githubusercontent.com/u/3327087?v=3","gravatar_id":"","url":"https://api.github.com/users/darioizzo","html_url":"https://github.com/darioizzo","followers_url":"https://api.github.com/users/darioizzo/followers","following_url":"https://api.github.com/users/darioizzo/following{/other_user}","gists_url":"https://api.github.com/users/darioizzo/gists{/gist_id}","starred_url":"https://api.github.com/users/darioizzo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darioizzo/subscriptions","organizations_url":"https://api.github.com/users/darioizzo/orgs","repos_url":"https://api.github.com/users/darioizzo/repos","events_url":"https://api.github.com/users/darioizzo/events{/privacy}","received_events_url":"https://api.github.com/users/darioizzo/received_events","type":"User","site_admin":false},"assignees":[{"login":"darioizzo","id":3327087,"avatar_url":"https://avatars.githubusercontent.com/u/3327087?v=3","gravatar_id":"","url":"https://api.github.com/users/darioizzo","html_url":"https://github.com/darioizzo","followers_url":"https://api.github.com/users/darioizzo/followers","following_url":"https://api.github.com/users/darioizzo/following{/other_user}","gists_url":"https://api.github.com/users/darioizzo/gists{/gist_id}","starred_url":"https://api.github.com/users/darioizzo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darioizzo/subscriptions","organizations_url":"https://api.github.com/users/darioizzo/orgs","repos_url":"https://api.github.com/users/darioizzo/repos","events_url":"https://api.github.com/users/darioizzo/events{/privacy}","received_events_url":"https://api.github.com/users/darioizzo/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/esa/pagmo2/pulls/13/commits","review_comments_url":"https://api.github.com/repos/esa/pagmo2/pulls/13/comments","review_comment_url":"https://api.github.com/repos/esa/pagmo2/pulls/comments{/number}","comments_url":"https://api.github.com/repos/esa/pagmo2/issues/13/comments","statuses_url":"https://api.github.com/repos/esa/pagmo2/statuses/09fa2887dd22e0e51881a75ab4b3cb365b6b2dd2","head":{"label":"darioizzo:cec2013","ref":"cec2013","sha":"09fa2887dd22e0e51881a75ab4b3cb365b6b2dd2","user":{"login":"darioizzo","id":3327087,"avatar_url":"https://avatars.githubusercontent.com/u/3327087?v=3","gravatar_id":"","url":"https://api.github.com/users/darioizzo","html_url":"https://github.com/darioizzo","followers_url":"https://api.github.com/users/darioizzo/followers","following_url":"https://api.github.com/users/darioizzo/following{/other_user}","gists_url":"https://api.github.com/users/darioizzo/gists{/gist_id}","starred_url":"https://api.github.com/users/darioizzo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darioizzo/subscriptions","organizations_url":"https://api.github.com/users/darioizzo/orgs","repos_url":"https://api.github.com/users/darioizzo/repos","events_url":"https://api.github.com/users/darioizzo/events{/privacy}","received_events_url":"https://api.github.com/users/darioizzo/received_events","type":"User","site_admin":false},"repo":{"id":78527940,"name":"pagmo2","full_name":"darioizzo/pagmo2","owner":{"login":"darioizzo","id":3327087,"avatar_url":"https://avatars.githubusercontent.com/u/3327087?v=3","gravatar_id":"","url":"https://api.github.com/users/darioizzo","html_url":"https://github.com/darioizzo","followers_url":"https://api.github.com/users/darioizzo/followers","following_url":"https://api.github.com/users/darioizzo/following{/other_user}","gists_url":"https://api.github.com/users/darioizzo/gists{/gist_id}","starred_url":"https://api.github.com/users/darioizzo/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/darioizzo/subscriptions","organizations_url":"https://api.github.com/users/darioizzo/orgs","repos_url":"https://api.github.com/users/darioizzo/repos","events_url":"https://api.github.com/users/darioizzo/events{/privacy}","received_events_url":"https://api.github.com/users/darioizzo/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/darioizzo/pagmo2","description":"A C++ / Python platform to perform parallel computations of optimisation tasks (global and local) via the asynchronous generalized island model.","fork":true,"url":"https://api.github.com/repos/darioizzo/pagmo2","forks_url":"https://api.github.com/repos/darioizzo/pagmo2/forks","keys_url":"https://api.github.com/repos/darioizzo/pagmo2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/darioizzo/pagmo2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/darioizzo/pagmo2/teams","hooks_url":"https://api.github.com/repos/darioizzo/pagmo2/hooks","issue_events_url":"https://api.github.com/repos/darioizzo/pagmo2/issues/events{/number}","events_url":"https://api.github.com/repos/darioizzo/pagmo2/events","assignees_url":"https://api.github.com/repos/darioizzo/pagmo2/assignees{/user}","branches_url":"https://api.github.com/repos/darioizzo/pagmo2/branches{/branch}","tags_url":"https://api.github.com/repos/darioizzo/pagmo2/tags","blobs_url":"https://api.github.com/repos/darioizzo/pagmo2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/darioizzo/pagmo2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/darioizzo/pagmo2/git/refs{/sha}","trees_url":"https://api.github.com/repos/darioizzo/pagmo2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/darioizzo/pagmo2/statuses/{sha}","languages_url":"https://api.github.com/repos/darioizzo/pagmo2/languages","stargazers_url":"https://api.github.com/repos/darioizzo/pagmo2/stargazers","contributors_url":"https://api.github.com/repos/darioizzo/pagmo2/contributors","subscribers_url":"https://api.github.com/repos/darioizzo/pagmo2/subscribers","subscription_url":"https://api.github.com/repos/darioizzo/pagmo2/subscription","commits_url":"https://api.github.com/repos/darioizzo/pagmo2/commits{/sha}","git_commits_url":"https://api.github.com/repos/darioizzo/pagmo2/git/commits{/sha}","comments_url":"https://api.github.com/repos/darioizzo/pagmo2/comments{/number}","issue_comment_url":"https://api.github.com/repos/darioizzo/pagmo2/issues/comments{/number}","contents_url":"https://api.github.com/repos/darioizzo/pagmo2/contents/{+path}","compare_url":"https://api.github.com/repos/darioizzo/pagmo2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/darioizzo/pagmo2/merges","archive_url":"https://api.github.com/repos/darioizzo/pagmo2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/darioizzo/pagmo2/downloads","issues_url":"https://api.github.com/repos/darioizzo/pagmo2/issues{/number}","pulls_url":"https://api.github.com/repos/darioizzo/pagmo2/pulls{/number}","milestones_url":"https://api.github.com/repos/darioizzo/pagmo2/milestones{/number}","notifications_url":"https://api.github.com/repos/darioizzo/pagmo2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/darioizzo/pagmo2/labels{/name}","releases_url":"https://api.github.com/repos/darioizzo/pagmo2/releases{/id}","deployments_url":"https://api.github.com/repos/darioizzo/pagmo2/deployments","created_at":"2017-01-10T11:37:29Z","updated_at":"2017-01-10T11:37:31Z","pushed_at":"2017-02-03T19:10:18Z","git_url":"git://github.com/darioizzo/pagmo2.git","ssh_url":"git@github.com:darioizzo/pagmo2.git","clone_url":"https://github.com/darioizzo/pagmo2.git","svn_url":"https://github.com/darioizzo/pagmo2","homepage":null,"size":7008,"stargazers_count":0,"watchers_count":0,"language":"C++","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"esa:master","ref":"master","sha":"1feae5cdd0bb1336126de9e7e83a80c3f0d5891c","user":{"login":"esa","id":3287599,"avatar_url":"https://avatars.githubusercontent.com/u/3287599?v=3","gravatar_id":"","url":"https://api.github.com/users/esa","html_url":"https://github.com/esa","followers_url":"https://api.github.com/users/esa/followers","following_url":"https://api.github.com/users/esa/following{/other_user}","gists_url":"https://api.github.com/users/esa/gists{/gist_id}","starred_url":"https://api.github.com/users/esa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/esa/subscriptions","organizations_url":"https://api.github.com/users/esa/orgs","repos_url":"https://api.github.com/users/esa/repos","events_url":"https://api.github.com/users/esa/events{/privacy}","received_events_url":"https://api.github.com/users/esa/received_events","type":"Organization","site_admin":false},"repo":{"id":78372913,"name":"pagmo2","full_name":"esa/pagmo2","owner":{"login":"esa","id":3287599,"avatar_url":"https://avatars.githubusercontent.com/u/3287599?v=3","gravatar_id":"","url":"https://api.github.com/users/esa","html_url":"https://github.com/esa","followers_url":"https://api.github.com/users/esa/followers","following_url":"https://api.github.com/users/esa/following{/other_user}","gists_url":"https://api.github.com/users/esa/gists{/gist_id}","starred_url":"https://api.github.com/users/esa/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/esa/subscriptions","organizations_url":"https://api.github.com/users/esa/orgs","repos_url":"https://api.github.com/users/esa/repos","events_url":"https://api.github.com/users/esa/events{/privacy}","received_events_url":"https://api.github.com/users/esa/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/esa/pagmo2","description":"A C++ / Python platform to perform parallel computations of optimisation tasks (global and local) via the asynchronous generalized island model.","fork":false,"url":"https://api.github.com/repos/esa/pagmo2","forks_url":"https://api.github.com/repos/esa/pagmo2/forks","keys_url":"https://api.github.com/repos/esa/pagmo2/keys{/key_id}","collaborators_url":"https://api.github.com/repos/esa/pagmo2/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/esa/pagmo2/teams","hooks_url":"https://api.github.com/repos/esa/pagmo2/hooks","issue_events_url":"https://api.github.com/repos/esa/pagmo2/issues/events{/number}","events_url":"https://api.github.com/repos/esa/pagmo2/events","assignees_url":"https://api.github.com/repos/esa/pagmo2/assignees{/user}","branches_url":"https://api.github.com/repos/esa/pagmo2/branches{/branch}","tags_url":"https://api.github.com/repos/esa/pagmo2/tags","blobs_url":"https://api.github.com/repos/esa/pagmo2/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/esa/pagmo2/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/esa/pagmo2/git/refs{/sha}","trees_url":"https://api.github.com/repos/esa/pagmo2/git/trees{/sha}","statuses_url":"https://api.github.com/repos/esa/pagmo2/statuses/{sha}","languages_url":"https://api.github.com/repos/esa/pagmo2/languages","stargazers_url":"https://api.github.com/repos/esa/pagmo2/stargazers","contributors_url":"https://api.github.com/repos/esa/pagmo2/contributors","subscribers_url":"https://api.github.com/repos/esa/pagmo2/subscribers","subscription_url":"https://api.github.com/repos/esa/pagmo2/subscription","commits_url":"https://api.github.com/repos/esa/pagmo2/commits{/sha}","git_commits_url":"https://api.github.com/repos/esa/pagmo2/git/commits{/sha}","comments_url":"https://api.github.com/repos/esa/pagmo2/comments{/number}","issue_comment_url":"https://api.github.com/repos/esa/pagmo2/issues/comments{/number}","contents_url":"https://api.github.com/repos/esa/pagmo2/contents/{+path}","compare_url":"https://api.github.com/repos/esa/pagmo2/compare/{base}...{head}","merges_url":"https://api.github.com/repos/esa/pagmo2/merges","archive_url":"https://api.github.com/repos/esa/pagmo2/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/esa/pagmo2/downloads","issues_url":"https://api.github.com/repos/esa/pagmo2/issues{/number}","pulls_url":"https://api.github.com/repos/esa/pagmo2/pulls{/number}","milestones_url":"https://api.github.com/repos/esa/pagmo2/milestones{/number}","notifications_url":"https://api.github.com/repos/esa/pagmo2/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/esa/pagmo2/labels{/name}","releases_url":"https://api.github.com/repos/esa/pagmo2/releases{/id}","deployments_url":"https://api.github.com/repos/esa/pagmo2/deployments","created_at":"2017-01-08T21:53:43Z","updated_at":"2017-01-30T03:34:34Z","pushed_at":"2017-02-03T19:10:18Z","git_url":"git://github.com/esa/pagmo2.git","ssh_url":"git@github.com:esa/pagmo2.git","clone_url":"https://github.com/esa/pagmo2.git","svn_url":"https://github.com/esa/pagmo2","homepage":null,"size":4945,"stargazers_count":4,"watchers_count":4,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":4,"forks":5,"open_issues":4,"watchers":4,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/esa/pagmo2/pulls/13"},"html":{"href":"https://github.com/esa/pagmo2/pull/13"},"issue":{"href":"https://api.github.com/repos/esa/pagmo2/issues/13"},"comments":{"href":"https://api.github.com/repos/esa/pagmo2/issues/13/comments"},"review_comments":{"href":"https://api.github.com/repos/esa/pagmo2/pulls/13/comments"},"review_comment":{"href":"https://api.github.com/repos/esa/pagmo2/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/esa/pagmo2/pulls/13/commits"},"statuses":{"href":"https://api.github.com/repos/esa/pagmo2/statuses/09fa2887dd22e0e51881a75ab4b3cb365b6b2dd2"}}}}
{"actor":{"display_login":"bluescarni"}}