Articles on bharath2438's Bloghttps://blogs.python-gsoc.orgUpdates on different articles published on bharath2438's BlogenThu, 22 Sep 2022 16:37:26 +0000XSPARSE Week - 14https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-14/<p>The past week was the most fruitful in terms of the implementation that we wanted to achieve in the end. The week was spent on providing the finishing touches to the existing co_iteration class and making sure that everything was done for the next steps to go on smoothly.</p> <h2><u>What I did this week</u></h2> <p>I was able to finish the operator overloads with regards to the iterator and make sure that things fell in place for easy iteration through structured bindings. I also started working on the == and the != operators. It took me a while to understand how to use the constexpr function in this context and I had a meeting with my mentor to clear a few things up.  </p> <h2><u>What is coming up next</u></h2> <p>Before getting the PR merged, I would think it is better to work on writing some tests and cleanup some parts of the code so that it is ready to aid in codegen.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did not get stuck anywhere during this week.</p>bharathkk0603@gmail.com (bharath2438)Thu, 22 Sep 2022 16:37:26 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-14/XSPARSE Week - 13https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-13/<p>This week, I worked extensively on the solution for merge lattices and even got some reviews from my mentor based on the code submitted.</p> <h2><u>What I did this week</u></h2> <p>I wrote co_iteration.hpp, which helps in iterating over n - levels when there is an input of n levels. It returns an iterator.</p> <h2><u>What is coming up next</u></h2> <p>I should be able to get this PR merged by this week and start working on the next codegen in the subsequent weeks.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did not get stuck anywhere during this week.</p>bharathkk0603@gmail.com (bharath2438)Tue, 13 Sep 2022 16:29:48 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-13/XSPARSE Week - 12https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-12/<p>The 12th week was significant as I was able to narrow down on what exactly needed to be done to achieve co-iteration. I had an additional meeting with my mentor, and we established that we were just going to focus on iterating over n-levels i.e take in n levels and output an iterator that goes over all the levels simultaneously. We also applied for an extension because that little bit of extra time was required to achieve the objectives.</p> <h2><u>What I did this week</u></h2> <p>I read the paper thoroughly and discussed with my mentor about the implementation details and the metaprogram that was needed to output the iterator. I also began working seriously towards getting the code part done because this had already taken about 3 weeks...</p> <h2><u>What is coming up next</u></h2> <p>In the next week, I should be able to finish the merge lattice part with coiteration and start working on the iteration graph. I will also try working on presenting the approach for coiteration in the next TACO conference, if possible.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did get stuck in many places and asked my questions to my mentor through github, gitter and also google meet. Eventually, I was able to get a clear picture of what had to be done.</p>bharathkk0603@gmail.com (bharath2438)Mon, 05 Sep 2022 17:25:32 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-12/XSPARSE Week - 11https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-11/<p>During the 11th week, I worked on the API for constructing merges.</p> <h2><u>What I did this week</u></h2> <p>The API for constructing merges was worked upon and my mentor and I were able to narrow down on the required codegen to construct union and intersection merges. </p> <h2><u>What is coming up next</u></h2> <p>I would focus on getting the level iterator merge API done by this week so that we can focus on the code generation algorithm from the next week.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did get stuck while trying to understand how this could be figured out but we had an intermediate meeting to sort some things out.</p>bharathkk0603@gmail.com (bharath2438)Mon, 29 Aug 2022 16:54:32 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-11/XSPARSE Week - 10https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-10/<p>The 10th week was dedicated to reading and understanding about co-iteration and implementing the API for merge lattices and emit intersection and union merges.</p> <h2><u>What I did this week</u></h2> <p>I spent the first half of the week reading and understanding iteration graphs and merge lattices so that I can implement codegen for emitting loops to iterate over the joint iteration space of two or more levels. I also created a PR so that I could communicate efficiently with my mentor on the details. I also got the tensor algebra compiler paper from my mentor so that I have all the details to work with AND and OR operators for an intersection and union merge respectively.</p> <h2><u>What is coming up next</u></h2> <p>I aim to complete the co-iteration API using the inputs given by my mentor and get it merged in the next week. It will be an important week as the codegen algorithm largely depends on the efficiency of the co-iter API. This has also been one of the hardest phases of the project for me as I need a thorough understanding of the concept to implement in C++.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did get stuck in the middle of the week as I felt I couldn't proceed further without clearly understanding the concept of merge lattices. Therefore, it was necessary to set up an impromptu meet with my mentor to clear a few things up before I could proceed.</p>bharathkk0603@gmail.com (bharath2438)Mon, 22 Aug 2022 16:55:06 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-10/XSPARSE Week - 9https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-9/<p>During the 9th week, I worked on level properties and got it merged.</p> <h2><u>What I did this week</u></h2> <p>I opened the level properties PR and made a few changes as suggested by my mentor. As soon as I was done with that, I started working on merging iterators which is a pre-requisite for code generation.</p> <h2><u>What is coming up next</u></h2> <p>I'm planning to focus on getting iterator merge and deduplication merged next week.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did not get stuck anywhere during the week.</p>bharathkk0603@gmail.com (bharath2438)Thu, 18 Aug 2022 14:20:36 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-9/XSPARSE - Week 8https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-8/<p>During the 8th week, I worked on changes to the level properties.</p> <h2><u>What I did this week</u></h2> <p>I discussed with my mentor on how to improve level properties so that it stays consistent with the container traits and base traits. I also worked on handling the configurable properties.</p> <h2><u>What is coming up next</u></h2> <p>I will focus on getting level properties merged and work on the deduplication loop next week</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did not get stuck anywhere during the week.</p>bharathkk0603@gmail.com (bharath2438)Wed, 10 Aug 2022 16:44:54 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-8/XSPARSE Week - 7https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-7/<h1>XSPARSE Week - 7</h1> <p>The 7th week was the week of the mid-term evaluation.</p> <h2><u>What I did this week</u></h2> <p>Unfortunately, I couldn't work this week as I had fever and body ache. I updated my mentor regarding the same and that I would resume work once I recovered.</p> <h2><u>What is coming up next</u></h2> <p>The next part will involve me working on level properties and the new paper that my mentor asked me to refer to.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did not get stuck anywhere during the week.</p>bharathkk0603@gmail.com (bharath2438)Thu, 04 Aug 2022 11:27:57 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-7/XSPARSE Week - 6https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-6/<p>In the 6th week, I worked fully on updating the API of containers.</p> <h2><u>What I did this week</u></h2> <p>I worked on a new PR this week which creates new container traits which can be used in the levels instead of hard coding them. This makes it more flexible as users can specify their own containers.</p> <h2><u>What is coming up next</u></h2> <p>My mentor suggested another paper from which we will be implementing deduplication and reordering. The main aim for the next week is to wrap up the container traits and understand the approaches mentioned in the paper.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did get stuck while working with template template parameters but my mentor helped me resolve the doubt.</p>bharathkk0603@gmail.com (bharath2438)Mon, 25 Jul 2022 12:01:17 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-6/XSPARSE Week - 5https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-5/<p>The 5th week was reserved for fixing the insert/append PR and moving on to level properties.</p> <h2><u>What I did this week</u></h2> <p>I completed the PR and fixed the tests and made some minor changes before the PR was merged. I had a discussion with my mentor regarding level properties and we decided that some changes to the API will be required.</p> <h2><u>What is coming up next</u></h2> <p>The next immediate goal is to wrap up level properties and brainstorm regarding code generation. The first half of the project needs to be finalized before the first review. </p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did not get stuck anywhere, there were only some minor fixes which I could fix on my own.</p>bharathkk0603@gmail.com (bharath2438)Fri, 22 Jul 2022 16:10:26 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-5/XSPARSE Week - 4https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-4/<p>The 4th week was the week of exams in my college and I could not concentrate regularly on the project, I informed the mentor about the same.</p> <h2><u>What I did this week</u></h2> <p>Although I couldn't spend a lot of time on GSoC as I was studying for exams, I could make some progress in completing the remaining levels' insert and append. Opening the PR before the end of the week was my goal.</p> <h2><u>What is coming up next</u></h2> <p>Once the insert/append PR is merged, I plan to quickly wrap up the level properties and move towards code generation.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did not get stuck anywhere during the implementation although I had to fix some small errors in the PR.</p>bharathkk0603@gmail.com (bharath2438)Wed, 13 Jul 2022 17:09:00 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-4/XSPARSE Week - 3https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-3/<p>Week 3 was spent in finishing up the hashed format and shifting focus to insert and append capabilities for all levels.  </p> <h2><u>What I did this week</u></h2> <p>I spent the week writing code for insert and append after adding some tests to the hashed format. Compressed was completed and the remaining levels had to be finished.</p> <h2><u>What is coming up next</u></h2> <p>In the next week, the plan is to concentrate on level properties and implement base classes for level properties.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did not get stuck anywhere as the coding part was straight-forward.</p>bharathkk0603@gmail.com (bharath2438)Wed, 13 Jul 2022 17:04:41 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-3/XSPARSE Week - 2https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-2/<p>The previous week was spent writing the hashed level format, which was quite different and not so straightforward compared to other formats.</p> <h2><u>What I did this week</u></h2> <p>I spent the week completing the hashed format and its <code>iter_helper </code>as we decided to use a vector of unordered maps as the container. I had to implement a bidirectional iterator as well as write 4 test-cases by combining the hashed level with other levels. I opened a PR and after a few changes, it was merged yesterday.</p> <h2><u>What is coming up next</u></h2> <p>In the next week, the plan is to concentrate on the append and insert capabilities of each level format. The same has been done for the hashed format already. If it gets over quickly, we move one step towards code generation.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>I did get stuck when writing a custom iterator for the unordered map but my mentor helped me by asking me to get a reference to the wrapped iterator and implement the different operators.</p>bharathkk0603@gmail.com (bharath2438)Thu, 30 Jun 2022 03:57:19 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-2/XSPARSE Week - 1https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-1/<p>I'll be working on XSparse which is a sparse array library written in C++.</p> <p>Last week marked the end of the community bonding period and the beginning of the coding period. I was able to get a head start during the community bonding period and opened <a href="https://github.com/hameerabbasi/xsparse/pull/5">this PR</a> which was merged.</p> <h2><u>What I did this week</u></h2> <p>I spent the week working on the hashed level format. My mentor and I had 2 discussions this week and decided that a slight deviation from the paper is required. I could implement 3 of the required functions and one of them is left to be implemented.</p> <h2><u>What is coming up next</u></h2> <p>In the next week, the plan is to get the hashed level get merged along with the test cases and finish the level formats. Also, we'll try to work from the code generation perspective in the next week so that everything falls into place.</p> <h2><u>Did I get stuck anywhere</u></h2> <p>Yes, I did get stuck on Wednesday in a few places in the implementation. I was able to prepare a list of questions to ask my mentor and we scheduled a meeting on Wednesday itself so that my doubts were cleared.</p>bharathkk0603@gmail.com (bharath2438)Sun, 19 Jun 2022 16:10:47 +0000https://blogs.python-gsoc.org/en/bharath2438s-blog/xsparse-week-1/