<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"><html><head><meta content="text/html;charset=UTF-8" http-equiv="Content-Type"></head><body ><div style="font-family: Verdana, Arial, Helvetica, sans-serif; font-size: 10pt;"><div>tHi, <br></div><div><br></div><div>Just a little bit correction, the module currently I am working on is IPCV, not SIVP. <img style="vertical-align: middle; width: 24px; height: 24px;" title="Smile" data-attr="smiley" src="cid:0.28869236100.5159708256601528207.170c01c6abb__smiley__img__src" width="24" height="24"><br></div><div><br></div><div>I overlooked the scicv in comparison previously as I was "<span class="highlight" style="background-color:rgb(255, 255, 255)"><span class="colour" style="color:rgb(51, 51, 51)"><span class="font" style="font-family:"Helvetica Neue", Helvetica, Arial, sans-serif"><span class="size" style="font-size:14px">intoxicated" in telling history of the modules related to IPCV.</span></span></span></span><br></div><div><br></div><div>In fact I was trying to work on scicv as well, as it is almost a complete set to link to the opencv library. As mentioned by Clement, the link to the opencv is generated by SWIG, and since it is automatic, there could be a lot of crashed in name. <br></div><div><br></div><div>On top of that, the syntax of the function are very similar to python, so it makes sense to for those switching from python to Scilab. <br></div><div><br></div><div>As it is just too much datatype in OpenCV, it is almost impossible to map each of everyone to Scilab. Hence, then only way is to leave the output of a function to be in "OpenCV space" and computation goes on until the final result which is then convert back to Scilab for the result. <br></div><div><br></div><div>For example, look at this tutorial : <a href="https://www.scilab.org/tutorials/computer-vision-%E2%80%93-structural-analysis" target="_blank">https://www.scilab.org/tutorials/computer-vision-%E2%80%93-structural-analysis</a><br></div><div><br></div><div>somewhere in the middle of the codes we have:<br></div><div><br></div><div><span class="highlight" style="background-color:rgb(255, 255, 255)"><span class="colour" style="color:rgb(68, 68, 68)"><span class="font" style="font-family:Raleway, "Open Sans", sans-serif, arial"><span class="size" style="font-size:16px">cont = contours(maxI);</span></span></span></span><br></div><div><span class="highlight" style="background-color:rgb(255, 255, 255)"><span class="colour" style="color:rgb(68, 68, 68)"><span class="font" style="font-family:Raleway, "Open Sans", sans-serif, arial"><span class="size" style="font-size:16px">hull = convexHull(cont);</span></span></span></span><br></div><div><span class="highlight" style="background-color:rgb(255, 255, 255)"><span class="colour" style="color:rgb(68, 68, 68)"><span class="font" style="font-family:Raleway, "Open Sans", sans-serif, arial"><span class="size" style="font-size:16px">hulld = double(hull(:));</span></span></span></span><br></div><div><br></div><div><span class="highlight" style="background-color:rgb(255, 255, 255)"><span class="colour" style="color:rgb(68, 68, 68)"><span class="font" style="font-family:Raleway, "Open Sans", sans-serif, arial"><span class="size" style="font-size:16px">this cont, hull are not Scilab variable, but cont required as the input for the convexHull function. If we convert it to Scilab var, then it will need to convert back to the opencv var to be accepted in the next function. hulld is the last result to convert to double.</span></span></span></span><br></div><div><br></div><div><span class="highlight" style="background-color:rgb(255, 255, 255)"><span class="colour" style="color:rgb(68, 68, 68)"><span class="font" style="font-family:Raleway, "Open Sans", sans-serif, arial"><span class="size" style="font-size:16px">About the opensource, from technical point of view, if I understand correctly, the whole module is generated by SWIG, and having the source is just... useless? or at least, once u have modified the source to fix some bugs, wait...this is provided the generated codes are readable. And once you modified it, the whole thing need to be maintained manually from that point onward? Else when the dev move to new version of OpenCV, the whole source will be refreshed again... (I could be wrong).</span></span></span></span><br></div><div><br></div><div>Let's switch to the coding style:</div><div><br></div><div>Let's compare if one need to implement function Hough transform:<br></div><div><br></div><div>in opencv, you can find the example of python, then follow the similar flow  to get to the end result. <br></div><div><br></div><div><a href="https://docs.opencv.org/4.1.2/d9/db0/tutorial_hough_lines.html" target="_blank">https://docs.opencv.org/4.1.2/d9/db0/tutorial_hough_lines.html</a><br></div><div><br></div><div>in IPCV, you can find the example in C/C++, then create a new gateway file under IPCV gateway folder, and add some lines in the source code from the example. </div><div><br></div><div><br></div><div>#include "Whatever" <br></div><div><br></div><div>int main(int argc, char** argv)<br></div><div>{<br></div><div>    // Declare the output variables<br></div><div>    GetImage()<br></div><div>    <br></div><div><br></div><div>    Mat dst, cdst, cdstP;<br></div><div>      .....<br></div><div>    HoughLines(dst, lines, 1, CV_PI/180, 150, 0, 0 ); // runs the actual detection<br></div><div>    .....<br></div><div><br></div><div>    SetImage()<br></div><div><br></div><div>    return 0;<br></div><div>}<br></div><div><br></div><div><br></div><div>The "GetImage" and "SetImage" is just an example of sending and passing the images/date to the gateway for computation, so this will create a function like: <br></div><div><br></div><div>out= imhough(S,m,n) ... <br></div><div><br></div><div>Which to choose is a preference of choice, at least, for me. <img ref="image" src="cid:0.28869236100.5159708256601528207.170c01c6abb__smiley__img__src" data-attr="smiley" title="Smile" style="vertical-align: middle; width: 24px; height: 24px;"><br></div><div><br></div><div>Hope this helps. <br></div><div><br></div><div><br></div><div>Regards,<br></div><div>Chin Luh</div><div><br></div><div><br></div><div><br></div><div><br></div><div><br></div><div class="zmail_extra" style="" data-zbluepencil-ignore="true"><div id="Zm-_Id_-Sgn1">---- On Mon, 09 Mar 2020 22:44:15 +0800 <b>Antoine Monmayrant <amonmayr@laas.fr></b> wrote ----<br></div><div><br></div><blockquote style="border-left: 1px solid rgb(204, 204, 204); padding-left: 6px; margin: 0px 0px 0px 5px;"><div class=" zm_4117384086037869911_parse_-342614667789240730"><div>Hello Clément,<br></div><div><br></div><div>Thanks for your answer.<br></div><div>I think it clarifies the situation somehow.<br></div><div>I still don't get your point of not open-sourcing it and maintaining it "for free".<br></div><div>I think it's the other way round: if you open-source it, it might happen that some members of the community contribute to extend it and maintain it "for free".<br></div><div>From the info you gave me, scicv should be avoided by any one not being that particular client of your group.<br></div><div>Moreover, scicv is adding noise and confusion to the atoms library.<br></div><div><br></div><div>Antoine<br></div><div><br></div><div><br></div><div>Le Lundi, Mars 09, 2020 15:29 CET, Clément David <<a href="mailto:Clement.David@esi-group.com" target="_blank">Clement.David@esi-group.com</a>> a Ã©crit:<br></div><div> <br></div><blockquote> <br></blockquote><div class="x_39902253WordSection1"><p class="MsoNormal">About the feature set, I suggest you take a look at SIVP which is much more complete and target a wider audience. The available functions are the documented ones and we might add more if customers requested more.<br></p><p class="MsoNormal"> <br></p><p class="MsoNormal">Currently, this toolbox is used by some customers and we only mapped the feature requested by them to have an associated minimal OpenCV build. It targets customers and we will probably not open-source it as we don’t want to maintain it â€œfor free”. Again if you want to co-develop, take a look at SIVP ; Chin Luh did a good job and it is open-source !<br></p><p class="MsoNormal"> <br></p><p class="MsoNormal">Regards,<br></p><p class="MsoNormal"> <br></p><p class="MsoNormal">Clément<br></p><p class="MsoNormal"> <br></p><p class="MsoNormal"> <br></p><div style="border: none;border-left: solid blue 1.5pt;padding: 0.0in 0.0in 0.0in 4.0pt;"><div><div style="border: none;border-top: solid rgb(225,225,225) 1.0pt;padding: 3.0pt 0.0in 0.0in 0.0in;"><p class="MsoNormal"><b>From:</b> users <<a href="mailto:users-bounces@lists.scilab.org" target="_blank">users-bounces@lists.scilab.org</a>> <b>On Behalf Of </b>Antoine Monmayrant<br><b>Sent:</b> Monday, March 9, 2020 2:34 PM<br><b>To:</b> Users mailing list for Scilab <<a href="mailto:users@lists.scilab.org" target="_blank">users@lists.scilab.org</a>><br><b>Subject:</b> Re: [Scilab-users] ?==?utf-8?q? Which module to use for hassle-free image processing with scilab ?</p></div></div><p class="MsoNormal"> <br></p><p>Hello Clément,<br><br>Thanks for your answer.<br>It's still not clear to me whether I should use scicv or not.<br>First, many features are missing and it's not clear to me how I can implement or discover them (hough transforms for example).<br>Is there a list of the opencv functions that you expose through swig and the one that are not implemented?<br><br>Also, I'm a bit surprised by your statement:</p><blockquote style="margin-top: 5.0pt;margin-bottom: 5.0pt;"><p>Note: the code is not open-source but SWIG for Scilab and OpenCV are!<br></p></blockquote><p class="MsoNormal">Why is it not open-source?<br>Is this some transient situation due to the way the code was developped (like for a client)?<br>Do you plan to make it open source in the near future?<br>For many reasons and lots of lessons learned the hard way, I don't feel like investing my time on non open-source software...<br><br><span lang="FR">Antoine<br><br><br><br>Le Lundi, Mars 09, 2020 10:52 CET, Clément David <</span><a href="mailto:Clement.David@esi-group.com" target="_blank"><span lang="FR">Clement.David@esi-group.com</span></a><span lang="FR">> a Ã©crit:<br> </span></p><blockquote style="margin-top: 5.0pt;margin-bottom: 5.0pt;"><p class="MsoNormal">Hello Antoine,<br><br>> - scicv: installs without any issue and as reported by Samuel (<br>> <a href="http://forge.scilab.org/index.php/p/scicv/issues/1944/" target="_blank">http://forge.scilab.org/index.php/p/scicv/issues/1944/</a><br>> <a href="http://forge.scilab.org/index.php/p/scicv/issues/1946/" target="_blank">http://forge.scilab.org/index.php/p/scicv/issues/1946/</a> ), overwrites 'write' and<br>> 'read' which breaks many native functions in scilab together with other useful<br>> modules (ie uman). This is a blocking issue that has not been fixed in the past 6<br>> months. Moreover, many opencv functions are not available and it is not clear<br>> how to access them.<br><br>About sciCV, the idea was to use SWIG [1] and OpenCV [2] as an easy to use (and simple to develop) toolbox for manipulating images and videos using Scilab scripts. Here we don't have Scilab scripts at all, just a bunch of SWIG rules to generate the Scilab C gateways from the OpenCV C API. We have a focus on keeping the data in the OpenCV world and "accessing" them from Scilab.<br><br>The two reported bugs have been fixed in 0.5 (sorry I did not close them) and the latest 0.6 version is built for Scilab 6.1.0 after a customer request.<br><br>Note: the code is not open-source but SWIG for Scilab and OpenCV are!<br><br><br>--<br>Clément<br>_______________________________________________<br>users mailing list<br><a href="mailto:users@lists.scilab.org" target="_blank">users@lists.scilab.org</a><br><a href="http://lists.scilab.org/mailman/listinfo/users" target="_blank">http://lists.scilab.org/mailman/listinfo/users</a><br> </p></blockquote><p class="MsoNormal"><br> </p></div></div><div><br></div><div> 
_______________________________________________ <br></div><div>users mailing list <br></div><div><a href="mailto:users@lists.scilab.org" target="_blank">users@lists.scilab.org</a> <br></div><div><a href="http://lists.scilab.org/mailman/listinfo/users" target="_blank">http://lists.scilab.org/mailman/listinfo/users</a> <br></div></div></blockquote></div><div><br></div><div><br></div><style>&ltbr&gt&ltbr&gt&ltbr&gt<br></style><div><br></div></div><br></body></html>