{"action":"closed","number":148,"pull_request":{"url":"https://api.github.com/repos/parallella/pal/pulls/148","id":37766912,"html_url":"https://github.com/parallella/pal/pull/148","diff_url":"https://github.com/parallella/pal/pull/148.diff","patch_url":"https://github.com/parallella/pal/pull/148.patch","issue_url":"https://api.github.com/repos/parallella/pal/issues/148","number":148,"state":"closed","locked":false,"title":"Fix :  image/conv2  &  dsp/conv,   p_median3x3_f32 : hardwired network ","user":{"login":"ebadi","id":1111940,"avatar_url":"https://avatars.githubusercontent.com/u/1111940?v=3","gravatar_id":"","url":"https://api.github.com/users/ebadi","html_url":"https://github.com/ebadi","followers_url":"https://api.github.com/users/ebadi/followers","following_url":"https://api.github.com/users/ebadi/following{/other_user}","gists_url":"https://api.github.com/users/ebadi/gists{/gist_id}","starred_url":"https://api.github.com/users/ebadi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebadi/subscriptions","organizations_url":"https://api.github.com/users/ebadi/orgs","repos_url":"https://api.github.com/users/ebadi/repos","events_url":"https://api.github.com/users/ebadi/events{/privacy}","received_events_url":"https://api.github.com/users/ebadi/received_events","type":"User","site_admin":false},"body":"dsp/p_conv_f32: Remove an extra element in the result, Fix a problem in involving uninitialize memory addresses in computation.                                  \r\nimage/p_conv2d_f32: Returns incorrect values as it doesn't flip the kernel in vertical and horizontal directions, Support for rectangular kernels.    \r\nimage/p_median3x3.c: For 3x3 median filter, I replaced it with hardwired median search described here: http:users.utcluj.ro/~baruch/resources/Image/xl23_16.pdf\r\nREADME.md: Typo\r\n\r\n\r\nCounter example for p_conv_f32\r\n\r\nResponse from FreeMat:\r\n```\r\n--> x = [1, 2, 3, 4];\r\n--> h = [5,6,7];\r\n--> r = conv(x, h)\r\nr =\r\n  5 16 34 52 45 28 \r\n```\r\nResponse from pal: \r\n100.000000, 105.000000, 116.000000, 134.000000, 152.000000, 145.000000, 128.000000, 100.000000\r\n\r\n```\r\n   float x[4] = {1,2,3,4};\r\n   float h[3] = {5,6,7} ;\r\n   float r[10] = {100,100,100,100,100,100, 100, 100,100, 100};  \r\n   p_conv_f32( x, h , r ,4 ,3);\r\n   printf (\"%f, %f, %f, %f, %f, %f, %f, %f\", r[0], r[1], r[2], r[3], r[4], r[5], r[6], r[7]);\r\n```\r\n\r\nCounter example for p_conv2d_f32\r\n\r\nResponse from FreeMat:\r\n```\r\n--> A= [17 24 1 8 15; 23 5 7 14 16; 4 6 13 20 22;10 12 19 21 3; 11 18 25 2 9]\r\n--> B=[1 3 1; 0 5 0; 2 1 2]\r\n--> E=[0 0 0; 0 1 0; 0 0 0]\r\n--> C2 = conv2(A,E,'valid')   <-- works correctly since kernel is symmetric   \r\n--> C1 = conv2(A,B,'valid')   <-- Doesn't work correctly\r\n\r\n120, 165, 205,\r\n160, 200, 245,\r\n190, 255, 235,\r\n```\r\n\r\nResponse from pal:\r\n155.0, 135.0, 200.0, \r\n145.0, 190.0, 230.0, \r\n185.0, 225.0, 270.0,\r\n\r\n```\r\n#define W 5\r\n#define W2 (W-2)\r\nint main(int argc, char *argv[])\r\n{\r\n   int i, j;\r\n   float src[5*5] = {17,24,1,8,15,\r\n                    23,5,7,14,16,\r\n                    4,6,13,20,22,\r\n                    10,12,19,21,3,\r\n                    11,18,25,2,9 };\r\n   float kernel[3*3] = {\r\n          1,3,1,\r\n          0,5,0,\r\n          2,1,2 };\r\n    float dest[3*3];\r\n    p_conv2d_f32(src, kernel, dest, 5, 5, 3);\r\n\r\n    for (i = 0; i < W; i++) {\r\n        for (j = 0; j < W; j++) {    \t\r\n        \tprintf(\"%.1f, \", src[i*W+j]);\r\n        }\r\n        printf(\"\\n\");\r\n    }\r\n    \r\n    printf(\"\\n\");\r\n    \r\n    for (i = 0; i < W2; i++) {\r\n        for (j = 0; j < W2; j++) {\r\n        \tprintf(\"%.1f, \", dest[i*W2+j]);\r\n        }\r\n        printf(\"\\n\");\r\n    }\r\n}\r\n```\r\n\r\nOld pull request : https://github.com/parallella/pal/pull/100","created_at":"2015-06-16T07:35:48Z","updated_at":"2015-06-16T13:17:09Z","closed_at":"2015-06-16T13:17:09Z","merged_at":"2015-06-16T13:17:09Z","merge_commit_sha":"f37f2d37d18bc993e87002712274016f3687c220","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/parallella/pal/pulls/148/commits","review_comments_url":"https://api.github.com/repos/parallella/pal/pulls/148/comments","review_comment_url":"https://api.github.com/repos/parallella/pal/pulls/comments{/number}","comments_url":"https://api.github.com/repos/parallella/pal/issues/148/comments","statuses_url":"https://api.github.com/repos/parallella/pal/statuses/c3508edfe32a484f5d046755e30efb5fbdf07575","head":{"label":"ebadi:master","ref":"master","sha":"c3508edfe32a484f5d046755e30efb5fbdf07575","user":{"login":"ebadi","id":1111940,"avatar_url":"https://avatars.githubusercontent.com/u/1111940?v=3","gravatar_id":"","url":"https://api.github.com/users/ebadi","html_url":"https://github.com/ebadi","followers_url":"https://api.github.com/users/ebadi/followers","following_url":"https://api.github.com/users/ebadi/following{/other_user}","gists_url":"https://api.github.com/users/ebadi/gists{/gist_id}","starred_url":"https://api.github.com/users/ebadi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebadi/subscriptions","organizations_url":"https://api.github.com/users/ebadi/orgs","repos_url":"https://api.github.com/users/ebadi/repos","events_url":"https://api.github.com/users/ebadi/events{/privacy}","received_events_url":"https://api.github.com/users/ebadi/received_events","type":"User","site_admin":false},"repo":{"id":37513209,"name":"pal","full_name":"ebadi/pal","owner":{"login":"ebadi","id":1111940,"avatar_url":"https://avatars.githubusercontent.com/u/1111940?v=3","gravatar_id":"","url":"https://api.github.com/users/ebadi","html_url":"https://github.com/ebadi","followers_url":"https://api.github.com/users/ebadi/followers","following_url":"https://api.github.com/users/ebadi/following{/other_user}","gists_url":"https://api.github.com/users/ebadi/gists{/gist_id}","starred_url":"https://api.github.com/users/ebadi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ebadi/subscriptions","organizations_url":"https://api.github.com/users/ebadi/orgs","repos_url":"https://api.github.com/users/ebadi/repos","events_url":"https://api.github.com/users/ebadi/events{/privacy}","received_events_url":"https://api.github.com/users/ebadi/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ebadi/pal","description":"An optimized C library for math, parallel processing and data movement","fork":true,"url":"https://api.github.com/repos/ebadi/pal","forks_url":"https://api.github.com/repos/ebadi/pal/forks","keys_url":"https://api.github.com/repos/ebadi/pal/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ebadi/pal/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ebadi/pal/teams","hooks_url":"https://api.github.com/repos/ebadi/pal/hooks","issue_events_url":"https://api.github.com/repos/ebadi/pal/issues/events{/number}","events_url":"https://api.github.com/repos/ebadi/pal/events","assignees_url":"https://api.github.com/repos/ebadi/pal/assignees{/user}","branches_url":"https://api.github.com/repos/ebadi/pal/branches{/branch}","tags_url":"https://api.github.com/repos/ebadi/pal/tags","blobs_url":"https://api.github.com/repos/ebadi/pal/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ebadi/pal/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ebadi/pal/git/refs{/sha}","trees_url":"https://api.github.com/repos/ebadi/pal/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ebadi/pal/statuses/{sha}","languages_url":"https://api.github.com/repos/ebadi/pal/languages","stargazers_url":"https://api.github.com/repos/ebadi/pal/stargazers","contributors_url":"https://api.github.com/repos/ebadi/pal/contributors","subscribers_url":"https://api.github.com/repos/ebadi/pal/subscribers","subscription_url":"https://api.github.com/repos/ebadi/pal/subscription","commits_url":"https://api.github.com/repos/ebadi/pal/commits{/sha}","git_commits_url":"https://api.github.com/repos/ebadi/pal/git/commits{/sha}","comments_url":"https://api.github.com/repos/ebadi/pal/comments{/number}","issue_comment_url":"https://api.github.com/repos/ebadi/pal/issues/comments{/number}","contents_url":"https://api.github.com/repos/ebadi/pal/contents/{+path}","compare_url":"https://api.github.com/repos/ebadi/pal/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ebadi/pal/merges","archive_url":"https://api.github.com/repos/ebadi/pal/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ebadi/pal/downloads","issues_url":"https://api.github.com/repos/ebadi/pal/issues{/number}","pulls_url":"https://api.github.com/repos/ebadi/pal/pulls{/number}","milestones_url":"https://api.github.com/repos/ebadi/pal/milestones{/number}","notifications_url":"https://api.github.com/repos/ebadi/pal/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ebadi/pal/labels{/name}","releases_url":"https://api.github.com/repos/ebadi/pal/releases{/id}","created_at":"2015-06-16T06:48:31Z","updated_at":"2015-06-16T06:48:33Z","pushed_at":"2015-06-16T07:26:03Z","git_url":"git://github.com/ebadi/pal.git","ssh_url":"git@github.com:ebadi/pal.git","clone_url":"https://github.com/ebadi/pal.git","svn_url":"https://github.com/ebadi/pal","homepage":"","size":3994,"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":"parallella:master","ref":"master","sha":"fcb69c4fb40c32f3c32daa6b452a97dbd7dd0050","user":{"login":"parallella","id":2919930,"avatar_url":"https://avatars.githubusercontent.com/u/2919930?v=3","gravatar_id":"","url":"https://api.github.com/users/parallella","html_url":"https://github.com/parallella","followers_url":"https://api.github.com/users/parallella/followers","following_url":"https://api.github.com/users/parallella/following{/other_user}","gists_url":"https://api.github.com/users/parallella/gists{/gist_id}","starred_url":"https://api.github.com/users/parallella/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/parallella/subscriptions","organizations_url":"https://api.github.com/users/parallella/orgs","repos_url":"https://api.github.com/users/parallella/repos","events_url":"https://api.github.com/users/parallella/events{/privacy}","received_events_url":"https://api.github.com/users/parallella/received_events","type":"Organization","site_admin":false},"repo":{"id":27394323,"name":"pal","full_name":"parallella/pal","owner":{"login":"parallella","id":2919930,"avatar_url":"https://avatars.githubusercontent.com/u/2919930?v=3","gravatar_id":"","url":"https://api.github.com/users/parallella","html_url":"https://github.com/parallella","followers_url":"https://api.github.com/users/parallella/followers","following_url":"https://api.github.com/users/parallella/following{/other_user}","gists_url":"https://api.github.com/users/parallella/gists{/gist_id}","starred_url":"https://api.github.com/users/parallella/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/parallella/subscriptions","organizations_url":"https://api.github.com/users/parallella/orgs","repos_url":"https://api.github.com/users/parallella/repos","events_url":"https://api.github.com/users/parallella/events{/privacy}","received_events_url":"https://api.github.com/users/parallella/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/parallella/pal","description":"An optimized C library for math, parallel processing and data movement","fork":false,"url":"https://api.github.com/repos/parallella/pal","forks_url":"https://api.github.com/repos/parallella/pal/forks","keys_url":"https://api.github.com/repos/parallella/pal/keys{/key_id}","collaborators_url":"https://api.github.com/repos/parallella/pal/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/parallella/pal/teams","hooks_url":"https://api.github.com/repos/parallella/pal/hooks","issue_events_url":"https://api.github.com/repos/parallella/pal/issues/events{/number}","events_url":"https://api.github.com/repos/parallella/pal/events","assignees_url":"https://api.github.com/repos/parallella/pal/assignees{/user}","branches_url":"https://api.github.com/repos/parallella/pal/branches{/branch}","tags_url":"https://api.github.com/repos/parallella/pal/tags","blobs_url":"https://api.github.com/repos/parallella/pal/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/parallella/pal/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/parallella/pal/git/refs{/sha}","trees_url":"https://api.github.com/repos/parallella/pal/git/trees{/sha}","statuses_url":"https://api.github.com/repos/parallella/pal/statuses/{sha}","languages_url":"https://api.github.com/repos/parallella/pal/languages","stargazers_url":"https://api.github.com/repos/parallella/pal/stargazers","contributors_url":"https://api.github.com/repos/parallella/pal/contributors","subscribers_url":"https://api.github.com/repos/parallella/pal/subscribers","subscription_url":"https://api.github.com/repos/parallella/pal/subscription","commits_url":"https://api.github.com/repos/parallella/pal/commits{/sha}","git_commits_url":"https://api.github.com/repos/parallella/pal/git/commits{/sha}","comments_url":"https://api.github.com/repos/parallella/pal/comments{/number}","issue_comment_url":"https://api.github.com/repos/parallella/pal/issues/comments{/number}","contents_url":"https://api.github.com/repos/parallella/pal/contents/{+path}","compare_url":"https://api.github.com/repos/parallella/pal/compare/{base}...{head}","merges_url":"https://api.github.com/repos/parallella/pal/merges","archive_url":"https://api.github.com/repos/parallella/pal/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/parallella/pal/downloads","issues_url":"https://api.github.com/repos/parallella/pal/issues{/number}","pulls_url":"https://api.github.com/repos/parallella/pal/pulls{/number}","milestones_url":"https://api.github.com/repos/parallella/pal/milestones{/number}","notifications_url":"https://api.github.com/repos/parallella/pal/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/parallella/pal/labels{/name}","releases_url":"https://api.github.com/repos/parallella/pal/releases{/id}","created_at":"2014-12-01T18:53:33Z","updated_at":"2015-06-16T12:40:41Z","pushed_at":"2015-06-16T13:17:09Z","git_url":"git://github.com/parallella/pal.git","ssh_url":"git@github.com:parallella/pal.git","clone_url":"https://github.com/parallella/pal.git","svn_url":"https://github.com/parallella/pal","homepage":"","size":3994,"stargazers_count":136,"watchers_count":136,"language":"C","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":73,"mirror_url":null,"open_issues_count":38,"forks":73,"open_issues":38,"watchers":136,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/parallella/pal/pulls/148"},"html":{"href":"https://github.com/parallella/pal/pull/148"},"issue":{"href":"https://api.github.com/repos/parallella/pal/issues/148"},"comments":{"href":"https://api.github.com/repos/parallella/pal/issues/148/comments"},"review_comments":{"href":"https://api.github.com/repos/parallella/pal/pulls/148/comments"},"review_comment":{"href":"https://api.github.com/repos/parallella/pal/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/parallella/pal/pulls/148/commits"},"statuses":{"href":"https://api.github.com/repos/parallella/pal/statuses/c3508edfe32a484f5d046755e30efb5fbdf07575"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"aolofsson","id":2229872,"avatar_url":"https://avatars.githubusercontent.com/u/2229872?v=3","gravatar_id":"","url":"https://api.github.com/users/aolofsson","html_url":"https://github.com/aolofsson","followers_url":"https://api.github.com/users/aolofsson/followers","following_url":"https://api.github.com/users/aolofsson/following{/other_user}","gists_url":"https://api.github.com/users/aolofsson/gists{/gist_id}","starred_url":"https://api.github.com/users/aolofsson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/aolofsson/subscriptions","organizations_url":"https://api.github.com/users/aolofsson/orgs","repos_url":"https://api.github.com/users/aolofsson/repos","events_url":"https://api.github.com/users/aolofsson/events{/privacy}","received_events_url":"https://api.github.com/users/aolofsson/received_events","type":"User","site_admin":false},"comments":2,"review_comments":0,"commits":2,"additions":66,"deletions":28,"changed_files":5}}