<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0" xmlns:cc="http://cyber.law.harvard.edu/rss/creativeCommonsRssModule.html">
    <channel>
        <title><![CDATA[Stories by Harshit Joshi on Medium]]></title>
        <description><![CDATA[Stories by Harshit Joshi on Medium]]></description>
        <link>https://medium.com/@josharshit?source=rss-8d20365fbb2a------2</link>
        <image>
            <url>https://cdn-images-1.medium.com/fit/c/150/150/0*q6IcxLjVPs--JYnM.</url>
            <title>Stories by Harshit Joshi on Medium</title>
            <link>https://medium.com/@josharshit?source=rss-8d20365fbb2a------2</link>
        </image>
        <generator>Medium</generator>
        <lastBuildDate>Fri, 04 Dec 2026 14:24:10 GMT</lastBuildDate>
        <atom:link href="https://medium.com/@josharshit/feed" rel="self" type="application/rss+xml"/>
        <webMaster><![CDATA[yourfriends@medium.com]]></webMaster>
        <atom:link href="http://medium.superfeedr.com/" rel="hub"/>
        <item>
            <title><![CDATA[How I cracked GSoC in my Freshman Year]]></title>
            <link>https://josharshit.medium.com/how-i-cracked-gsoc-in-my-freshman-year-febcda1670a9?source=rss-8d20365fbb2a------2</link>
            <guid isPermaLink="false">https://medium.com/p/febcda1670a9</guid>
            <category><![CDATA[debian]]></category>
            <category><![CDATA[github]]></category>
            <category><![CDATA[google-summer-of-code]]></category>
            <category><![CDATA[open-source]]></category>
            <category><![CDATA[gsoc]]></category>
            <dc:creator><![CDATA[Harshit Joshi]]></dc:creator>
            <pubDate>Mon, 28 Jan 2019 11:31:00 GMT</pubDate>
            <atom:updated>2021-01-20T09:09:27.863Z</atom:updated>
            <content:encoded><![CDATA[<figure><img alt="" src="https://cdn-images-1.medium.com/max/801/1*GM7LxFytFWM6Innk-we0zQ.png" /><figcaption>Hopefully, reading this blog will help you to get your name on this certificate.</figcaption></figure><p>Last month or so, Google announced Google Summer of Code 2019, and I have been bombarded with queries from many Google Summer of Code aspirants asking for tips on how to crack GSoC. I have also seen students asking in Debian’s outreach mailing list how to contribute to the Debian Project and eventually get selected for Google Summer of Code 2019. Therefore, I will try to resolve some queries in this blog and hope it helps you get going on open source projects and ultimately crack the Google Summer of Code.<br>I will write this blog replying to various questions that I have been asked. So, this will be in a question-answer format, or some might say my interview with myself.</p><h3>How did you start contributing to Open Source projects?</h3><p>In my 12th standard I heard about Google Summer of Code, I did not know what it was and how to get selected but I knew it’s somewhat prestigious and one should at least try to get selected in it. Then, I got lucky when I choose Cluster Innovation Centre, Delhi University for my undergraduate. Being a batch of 40 odd students it’s easy to interact with seniors and alumni. I attended a workshop organized by HashInclude on ‘<em>Open Source development and GSoC’. </em>It was taken by two times GSoCer Rajan Maurya and Pawan Pal. Both of them are alumni of Cluster Innovation Centre. They suggested us to start reading codes on Github and upload our projects to get acquainted with Github Platform and Open Source Development. Hence, I pushed a few course projects to Github in November.</p><p>We, at Cluster Innovation Centre, also organized the first version of CIC Month of Code (CMoC) to help students know about Open Source projects and to build their Open Source profile. It&#39;s similar to the GSoC format where students pick projects suggested/submitted by Open Source Torchbearers.</p><h3>When did you start preparing for Google Summer of Code?</h3><p>I first looked at GSoC projects and organizations in October. Just glanced through them. It was of no actual use, except for the part that it demoralized me, telling me these projects are way over my level. In truth, they were really good projects for a first-year student.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/1024/1*JEc9TKfgaFSH4jWx9f5UTQ.png" /></figure><p>I didn’t really prepare for GSoC per se. GSoC organizations for 2018 were declared in February and I gave them a look. Then, I searched for organizations that worked with C++ or python. There were a lot of them. In my first iteration, I skipped some well-known organizations like Debian, Mozilla, VideoLan, etc, thinking that obviously they have an excellent outreach and selection would be difficult if applied to them. I started reading some projects and joined a few slack/IRC groups.</p><p>In my second iteration, one of my friends told me to give a look at Debian. He said, they have interesting and less complicated python projects, and Voila! I discovered invoice2data.</p><h3>After selecting a project how did you contribute to it?</h3><p>This is the process that requires dedication more than anything. I read the documentation of the project, looked into the engine, researched about Regular Expressions. While going through the documentation of the project. I found a typo and Bang, there goes my first Push Request and my first contribution to the project. For the whole month, I tried to have as much conversation with the project mentor Manuel Riel as possible and didn’t even look at any other project. I made 9–10 PRs out of which 5–6 got merged. They weren’t major changes but minor fixes and features which helped my understanding of the project.</p><h3>How did you write your proposal?</h3><p>My proposal for GSoC was short but informative. It was about 5 pages long with all the possible description that I can give. Yes, 5 pages is a small proposal length. I made sure, I filled everything that Debian asked me to put into the proposal from my availability to what my workplace will be. This was my proposal: <a href="https://docs.google.com/document/d/1sERGUbsnxs5EP5IcHZ6iXQJZQ7EbOpR6t0kmiWWGuk8/edit?usp=sharing">Debian Proposal</a></p><h3>What should a student who wants to work with Debian Project do?</h3><figure><img alt="" src="https://cdn-images-1.medium.com/max/220/1*xZ_cQGbxfMQSFz9518qGuA.png" /></figure><p>Debian Community is one of the most democratic and helpful community I have come across. Everyone tries to help each other out. Right now, I would suggest you subscribe to their <a href="https://lists.debian.org/debian-outreach/">outreach mailing list.</a> You should also go through this <a href="https://lists.debian.org/debian-outreach/2018/11/msg00009.html">thread.</a></p><h3>What are your tips for Google Summer of Code 2019 aspirants?</h3><p>There are a few tips I would like to give:</p><ul><li>Google Summer of Code does not want coding experts but wants students to get started with Open Source development and hence if you are a coding novice (like I was), don’t let it stop you from applying for GSoC.</li><li>I have found is that it’s more important to make the project mentor believe that you will continue working with the project and will complete it rather than how much coding experience or expertise do you have.</li><li>It’s really important to interact with the project mentor and keeping him in the loop for things you do. But, don’t constantly bug them.</li><li>Don’t meddle with a lot of projects take your time to select a project but then give your full dedication and time to it.</li><li>Start contributing to projects after the organizations are announced and the organizations give their project ideas. Keep contributing to the project until the results are announced. It’s really important to contribute when the application period is going on.</li><li>Read a few previous project proposal before writing your own for the organization you want to apply for.</li></ul><p>My Github profile: <a href="https://github.com/duskybomb">https://github.com/duskybomb</a></p><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=febcda1670a9" width="1" height="1" alt="">]]></content:encoded>
        </item>
        <item>
            <title><![CDATA[Breaking Captcha: Validation Accuracy vs Test Accuracy]]></title>
            <link>https://josharshit.medium.com/breaking-captcha-validation-accuracy-vs-test-accuracy-a89a254d538a?source=rss-8d20365fbb2a------2</link>
            <guid isPermaLink="false">https://medium.com/p/a89a254d538a</guid>
            <category><![CDATA[convolutional-network]]></category>
            <category><![CDATA[machine-learning]]></category>
            <category><![CDATA[deep-learning]]></category>
            <category><![CDATA[captcha]]></category>
            <dc:creator><![CDATA[Harshit Joshi]]></dc:creator>
            <pubDate>Wed, 23 Jan 2019 17:38:39 GMT</pubDate>
            <atom:updated>2019-01-23T17:38:39.231Z</atom:updated>
            <content:encoded><![CDATA[<h4>This is the first part of the series “How to make a simple captcha breaker”. Let’s call this one “How not to make a simple captcha breaker”.</h4><p>I have been recently exploring Convolutional Neural Networks, or as LeCun would call them ConvNets (No, not CNN, there is a different story about this all together). After getting a brief idea from Jeremy Howard’s Fast.ai course and Deeplearning.ai’s Deep Learning Specialization course, yesterday I thought about making a simple captcha break to scrap my university results. One as simple as the one shown below.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/100/1*tHpiykZZRfJk4DfJjmkS0w.jpeg" /><figcaption>Captcha that my university uses.</figcaption></figure><p>My plan to go forward was pretty simple and was divided into three steps. First, make training dataset. Second, train model on the dataset and finally, pulling the image from the website and predict the captcha output.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/552/1*9bbe79OqoNBWVK4ulaAPfg.png" /></figure><h3><strong>Make Training Dataset</strong></h3><p>I made images using PILLOW which had one character in ‘Arial italics’ font because it was the closest one to my test dataset.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/641/1*kViHRCiQ1pylwOfskFB0nw.png" /><figcaption>Training dataset for 1. Similarly, I created dataset for numbers 0 to 9</figcaption></figure><pre>from PIL import Image, ImageDraw, ImageFont<br>import os<br>import shutil<br>import random<br><br>ROOT_PATH = &#39;dataset/&#39;<br>PATH = &#39;dataset_num/&#39;<br>if os.path.isdir(ROOT_PATH):<br>    shutil.rmtree(ROOT_PATH)<br><br>for i in range(11):<br>    os.makedirs(ROOT_PATH + PATH + str(i))<br><br>num_start = 0<br>num_end = 10<br><br><br>def make_captcha():<br>    for num in range(num_start, num_end):<br>        for i in range(1000):<br>            img = Image.new(&#39;RGB&#39;,<br>                            (25, 25),<br>                            color=(255, 255, 255))<br>            fnt = ImageFont.truetype(&#39;fonts/arial_italics.ttf&#39;,<br>                                     16)<br><br>            d = ImageDraw.Draw(img)<br>            d.text((random.random()*10, random.random()*10),<br>                   str(num),<br>                   font=fnt,<br>                   fill=(54, 90, 64))<br>            if num == 0:<br>                img.save(f&#39;{ROOT_PATH}{PATH}10/{str(i)}.jpg&#39;)<br>            else:<br>                img.save(f&#39;{ROOT_PATH}{PATH}{num}/{str(i)}.jpg&#39;)<br><br><br>if __name__ == &#39;__main__&#39;:<br>    make_captcha()</pre><h3><strong>Train Model on Dataset</strong></h3><p>Since the data is not too varying and we know, train and test data are very similar, the training part was fairly simple.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/517/1*E2_iW9TCmjTmCHZbfAhhvQ.png" /><figcaption>Model used to train dataset</figcaption></figure><p>I will share the code for training the model in the second part of this series. The important thing to note is the After 5 epochs, I was getting <strong>train accuracy=100%</strong> and<strong> validation accuracy as 100%</strong>. Which is pretty good and I was really happy.</p><h3><strong>Predict Captcha from Website</strong></h3><p>After the training part, it was time to test the model. For this, I gathered a test image from my Universities portal and predicted the outcome. The plan was:</p><ol><li>to grab the image and slice it into 6 parts each containing a number.</li><li>Then, predict the 6 slices individually using contours of OpenCV</li><li>Finally, concatenate the predictions.</li></ol><p>I ran the script to predict the outcome and Voila! the result was embarrassing. <strong>The model was able to predict only one number correctly. </strong>Now, was the time to debug it and see where did I go wrong. When I had a look at the number slices on which predictions were being made, I understood where the problem was.</p><p>While slicing the image, some noise was introduced from the neighbouring numbers. Here is an example.</p><figure><img alt="" src="https://cdn-images-1.medium.com/max/398/1*vIURpZ6fN967Of5beBX0Yw.png" /><figcaption>Notice the noise (white pixels) in each slice</figcaption></figure><h3>Conclusion</h3><p>Here is the learning:</p><ol><li>don’t get too excited even if your model gives 100% accuracy on your training and validation dataset.</li><li>Validation and test dataset should come from the same source. (I failed Andrew Ng). In this case, the training dataset should also be from the same data source as the number of test cases is limited</li></ol><img src="https://medium.com/_/stat?event=post.clientViewed&referrerSource=full_rss&postId=a89a254d538a" width="1" height="1" alt="">]]></content:encoded>
        </item>
    </channel>
</rss>