Latest Blog Posts

I write about things I'm: learning, building, organizing, and thinking about.

Check out my security blog here
Adding an Astro Search Bar

Adding an Astro Search Bar 7/26/2024

I recently reworked my portfolio website to focus heavier on blogs, and this included adding a search bar to search across across my site. In this blog post I'll walk you through how you can add your own! If you're just interested in the code here it is as a template website. Adding Search For search, I wanted a locally powered search engine so I don't have to pay or rely on third party APIs as my site only has a handful of pages and is small enough to handle in-browser search fast. To make our lives easier we'll be using astro-pagefind which uses the pagefind as a search engine. Installing First install the package into your astro project. After that's installed we have to add the integration into our Astro config. Next, let's make a basic search page. This is all you need for the most basic search functionality. Next, we need to generate the search index which pagefind will use to efficiently query your site. You can do this manually but I modified my package.json to do this automatically for me. :::note You might get some typescript warnings since the pagefind might have some unused variables Now if you go to your search page at http://localhost:4321/search you should be able to use the search bar. !Basic Search I wanted to change the component's functionality a little bit, and by following this blog I added: the search query as a url parameter, and focusing the input when the page loads. Next, let's make a new astro component slightly modified from the component that we're already using in our code that implements these features. The changed new code is highlighted. ``astro title="components/AstroSearch.astro" {48-53, 57, 63-70} --- import "@pagefind/default-ui/css/ui.css"; export interface Props { readonly id?: string; readonly className?: string; readonly query?: string; readonly uiOptions?: Record<string, any>; } const { id, className, query, uiOptions = {} } = Astro.props; const bundlePath = ${import.meta.env.BASE_URL}pagefind/; --- <div id={id} class:list={[className, "pagefind-init"]} data-pagefind-ui data-bundle-path={bundlePath} data-query={query} data-ui-options={JSON.stringify(uiOptions)} > </div> <script> // @ts-ignore import { PagefindUI } from "@pagefind/default-ui"; function initPageFind() { const allSelector = "[data-pagefind-ui]"; for (const el of document.querySelectorAll( ${allSelector}.pagefind-init )) { const elSelector = [ ...(el.id ? [#${el.id}] : []), ...[...el.classList.values()].map((c) => .${c}), allSelector, ].join(""); const bundlePath = el.getAttribute("data-bundle-path"); const opts = JSON.parse(el.getAttribute("data-ui-options") ?? "{}"); new PagefindUI({ ...opts, element: elSelector, bundlePath, }); el.classList.remove("pagefind-init"); var query = el.getAttribute("data-query"); // Check if the current URL has any query params const url = new URL(window.location.href); const params = new URLSearchParams(url.search); if (params.has("q")) { query = params.get("q"); } const input = el.querySelector<HTMLInputElement>(input[type="text"]); input?.focus(); if (input) { input.value = query; input.dispatchEvent(new Event("input", { bubbles: true })); // Add Listener to update the URL when the input changes input.addEventListener("input", (e) => { const input = e.target as HTMLInputElement; const url = new URL(window.location.href); const params = new URLSearchParams(url.search); params.set("q", input.value); window.history.replaceState({}, "", ${url.pathname}?${params}); }); } } } document.addEventListener("astro:page-load", initPageFind); if (document.readyState === "loading") { document.addEventListener("DOMContentLoaded", initPageFind); } else { initPageFind(); } </script> ` Then to use our new custom search component in pages/search.astro, we just import our custom component instead of the pre-defined one. Configuring Search Information All of the search information is controlled by pagefind, the documentation on configuring the search information is good, but I'll briefly cover what I found useful. :::note After making changes to how pagefind finds data about your site, you'll need to rebuild the index either manually with the pagefind --site dist/ command, or re-run the modified npm run dev from earlier. Ignoring Pages By default, it will search all pages. For me, this led to duplicate information matches as it would not only find the data for each post. It would also capture the same information on the page listing all of my blogs. To get around this on my page listing the blogs I added data-pagefind-ignore as an html attribute. Like this This prevents pagefind from indexing data within that tag. Showing Images I also wanted images to show up for each post in the search bar, as each of my articles have a thumbnail attached to them. First, set showImages: true By default, pagefind will try to find images on the page, but I found this pretty unreliable. Instead you can manually specify where the images are with an attribute on an img tag. This also does work on astro's <Image> component. :::note If you're using optimized images, you might notice that the images on the search results break after optimizing them. Don't worry! They'll work once deployed, and if you want to verify locally that it still works you can do so with astro preview, however they break while using astro dev` due to the search index being built on the optimized image paths which change. With these changes we get a search with images !Search With Images Styling Pagefind has a section about customizing the styles of the search bar. However, again I'll cover what I did here. By default it adds these css variables. I'm using DaisyUI and I wanted my colors to automatically switch when my theme does, so I ended up settling on the following styling. Then just import your styles into your search component, making sure it's after the default css import. After these changes (and some restyling of the default astro blog template), we end up with !Search with DaisyUI light And it automatically also works on other DaisyUI themes, dark shown. !Search with DaisyUI dark And that's all you have to do to get search working on your site! If you're looking to customize the search bar more definitely make sure to take a look at the pagefind docs yourself as it's fairly configurable. Here's a template website with optimized images and a search bar.

Astro Optimized Images With Markdown

Astro Optimized Images With Markdown 7/26/2024

I recently upgraded my site to a newer version of Astro that supported image optimization and I wanted to use that feature. I'll walk you through it, and it's a fairly quick change to improve the load times and the sizes of images you're serving to end users. If you're just interested in the code here it is as a template website. First, we need to move all of our images that we're serving into src instead of in the public folder. The public folder contents are all directly copied over in the build folder without pre-processing. Anywhere in your code that you have statically defined links to images like After moving the image from public/assets into src/assets we can replace it with the following. By using <Image> Astro will automatically optimize your image for the web at build-time, and that's all you have to do for statically linked images. With Dynamic Images From Blogs This is where it gets a little bit tricker as we can't dynamically import images from blogs, however Astro has a feature to make this possible. In your src/content/config.ts you might have something like this. For us to be able to use the image in an <Image> component, we have to update the schema to be of the image type. Next for each of your blogs update your metadata to point to the image now in the src folder. Then update any references to images in your markdown itself. After that, as we did before, update any references that were using <img> to use <Image>. Then, Astro will automatically optimize all of your images! Here's a template website with optimized images and a search bar.

IMC Prosperity 2

IMC Prosperity 2 5/3/2024

I recently competed in the IMC Prosperity 2 competition and I wanted to write a blog post about my experience as a first time competitor in a trading competition in addition to writing about some of the strategies I used for each round and how overall it turned out. What is IMC Prosperity 2? IMC Prosperity 2 is a competition where you trade virtual assets in a simulated market. There are multiple rounds and each round has a different set of rules and assets to trade. The goal is to make as much money as possible by the end of the competition. The two main types of trading are algorithmic trading and manual trading. In algorithmic trading, you write a program that automatically trades assets based on certain rules. In manual trading, you manually make trades based on the information you have. Round 1 Algorithmic Trading We had two good one was an amethyst which was considered relatively stable at 10K so we just did a strategy to buy below and sell at or above. We also had starfruit which were more unstable and varied often in prices and we just traded based on observed price change with respect to amethysts. Manual Trading The first round of the manual trading was pretty simple. We had to find two values between 900 and 1000 that would maximize our profits. We had an unkown amount of fish that would sell their gear to us at a linear probability from 0% at 900 to 100% at 100 and we were guaranteed to sell the gear at 1000 at the end of the round. The first value you picked was your first bid which was the price you'd pay for any gear that was offered by fish which that willingness to sell or less and the second value was a higher price to capture more profit. Our team calculated the value to be 952 and 978 but then we did some simulations and ran 950 and 980 as our final answers which got us tied for fourth with like 20 other teams but the optimal answer was 952 and 978. At the end of this round we were Overall ~700 Tied for 4th in the manual trading Somewhere in the 700s for the algorithmic trading Round 2 Algorithmic Trading This one was annoying we had to obsrve some conditions of an Orchid to determine the prediction time out of that. Honestly I did not have much time to work on this section so I just had a simple strategy implemented and did not bother understanding how to trade Orchids out. So to maintain a good score I just traded Amethysts and Starfruits again. Manual Trading This one was about finding the right conversion process to get the optimal outcome like converting through a few items to end up with the most seashells so we just wrote a program to iterate through all the possible combinations and find the best one. At the end of this round we were Overall 674, #200 in US Tied for 4th in the manual trading with 10 teams Still ~700 overall for algorithmic Round 3 Algorithmic Trading This one was about trading different bundles. So we had a gift basket made up of 1. Four CHOCOLATE bars 2. Six STRAWBERRIES 3. A single ROSES We could not bundle these items together ourselves or break them apart so we had to just trade the items directly. We ended up using a strategy on each of the items separately, and traded them based on the price jumps in some window period. For the baskets though we estimated the price of the basket based on a weighted sum of the individual items and bought/sell based on that. I mentioned the profit we got from just this round in the Discord and I started getting DMs from people on top 250 to compare strategies so I think we did pretty well in this round. Manual Trading This section was actually really interesting. We were given a list of tiles below. !Treasure Map So the base reward on each tile was 7.5K and the multiplier for each tile is different and the goal was to find the optimal reward when the reward is split between the number of hunters on that tile already. For example the 100x tile's reward to you would be 7.5K * 100 / (1 + 8). So your reward would be 83.3K since it's split between you and the hunters. The reason this is complicated is that for each 1% of the players that pick a given tile the number of hunters on that tile increases by 1. So you have to predict where the other players will go and try to go to a tile that has the least amount of players on it. Some players tried to make spreadsheets to collect responses from other players to try to predict where they would go but we just wrote a program to simulate the game and pick the best tile based on that. Finally the last interesting part is that each search you can do costs money. You can do 3 searches here are their costs. 1. Free 2. 25K 3. 75K There's definitely no right strategy here but here's what we were doing. We were hoping not everyone would act rational and we could hedge our bets a little bit here. We assumed everyone would be playing optimally and then calculated the tiles with the highest EV from that assumption then randomized our picks a little bit. And ended up picking I26 and H29 which were around the 1st optimal and the 6th optimal based on if everyone else played optimally. We thought that people might not play optimally if they assumed other people played optimally they'd pick different tiles and were hedging our bets that maybe people psych'd themselves out of playing optimally and picked the 1st optimal and also a lower optimal tile incase people were trying to pick the optimal one. There's no way to know if this was the right strategy since it relied on other people's decisions. At the end of this round we were Overall #374, #109 in US Unfortunatly we dropped to #390 in the manual trading However we jumped significantly in the algo trading to #492 Round 4 Algorithmic Trading This one was about trading coconut coupons which were analogous to options. We had to predict the price of the coconut at the end of the round and trade based on that. We made a black scholes model to predict the price of the coconut coupons and compared it to the actual prices of the coupons to determine if we should buy or sell. We did end up making a mistake in our model that actually ended up making a good amount of money but only really when the price was going down of the coconut coupon. We implemented a bug free version that was getting less money on the submission as a result of it. Acknowledging that this was a mistake, however we essentially decided to gamble on this round because to have a shot at getting a prize we needed to catch up significantly to the top teams by a few 100Ks and we were not going to do that by playing it safe. The algorithm wasn't losing too much money when it was going up in price because it was being subsidized by our very good result and algorithm from round 3 so we just decided to go for it. Manual Trading This time is was the same as the other manual trade where we had to optimize the price we'd pay for gear from fish. However in this one the first bid would be not changed and would work the same however the second bid the fish knew the total average of the bids and would sell if your bid was higher than the average and if your bid was below it would probablistically sell based on the difference between your bid and the average. We picked 960 and 980. We wanted to get more profit from the first guess because we expected the second guess we'd make less money from because of the average. Oh yeah during this round I also got recognized in the Discord chat from my GitHub profile picture 😭 !Getting Recognized But anyways, at the end of this round we were Overall #364, #102 in US We did rise to #303 in manual We rose to #401 in algorithmic Round 5 I barely participated in this one and it was just giving us access to who had done the trades in the past so you could infer trading side connections and stuff but we didn't end up doing that. Overall Results #381 Overall We ended up getting #103 in the US Conclusion This was my first time competing and learning about algorithmic trading and I had a lot of fun. I did use a lot of knowledge from the previous year's code and writeups to help me out, but I'm most proud that the round that we did the best on and seemed competitive with the top teams was one of the rounds where I ended up writing the code from scratch. I think I learned a lot about how to approach these problems and will likely compete in similar competitions in the future. Hopefully people found this blog post interesting and if you have any questions about my strategy if you're competing in the future feel free to reach out to me on LinkedIn The code is also a mess but if you want to see it you can check it out here

My UW Madison Course Tier List

My UW Madison Course Tier List 4/25/2024

I'm about to graduate from UW Madison and I thought I'd share my thoughts on the classes that I've taken. I'm a Computer Science major with a certificate in Entrepreneurship, which I'll talk about in the later sections. These are generally ranked by how much I enjoyed the class and how much I felt like I learned from the class. These are 100% the correct rankings and you should take my word as gospel and they're definitely not just my opinion. CS 500+ Level Courses S Tier For this tier these are the classes that you should take if you have the chance to take them. They're the most interesting and the most beneficial to you in terms of learning and experience. 642 - Information Security This class is probably my favorite class I've taken throughout my degree. I took it with Rahul Chatterjee and I know that some people don't like his lectures however I did enjoy them. I came into the class as someone who was interested in the field of security and who liked breaking systems particularly in my web scraping experience. However I didn't know much about the real fundamentals of information security and this class was a survey course about a lot of the different topics that are in the field, most of which I enjoyed. Topics Covered This is the list of the topics that were covered in the course when I took it, however I believe that the specific topics changes from semester to semester. We had 75 minute lectures twice a week. OS Security (2 lectures) General OS Security Unix & Multics File System Vulnerabilities Access Control Android Security Software Security (4 Lectures) Low Level Security Buffer Overflows Heap Overflows Integer Overflows Format String Vulnerabilities Detecting Vulnerabilities Stack Canaries ASLR W^X Software Fault Isolations Cryptography (4 Lectures) Symmetric Encryption Block ciphers & different modes Hashing, MAC AEAD Encryption Scheme Asymmetric Encryption RSA Sharing Keys Diffie-Hellman Source of Randomness User Authentication Passwords & PINs Entropy, Guessing Attacks Leaked Passwords, HIBP Biometrics Web Security Browser Security CORS SQL Injection CSRF Clickjacking Defenses Network Security (3 Lectures) TLS Trust in the internet How do certificate authorities work Certificate issuance & revocation DNS, MAC DNS, DNSsec SYN Flood Wireshark, Firewall, IDS Censorship, Anonymity, & Tor Hardware Security (1 Lecture) TEE, TPM, SGX, Bitlocker Flush + Reload, Prime + Probe IoT Security Special Lectures (1 each) Cryptocurrency Machine Learning Security & Privacy Human Aspects of Security Assignments: 4 Homeworks These are relatively easy, except for the first one it gets so much easier after the first homework which is like 10 buffer overflow attacks 1 Midterm 1 Final Group Project ~3 Page Research Paper on some security topic 10 minute presentation to the class I definiely would have taken this class again and I would recommend it to anyone who is interested in the field of security as it gives you a good overview of the field and some of the topics that you might want to dive deeper into. 537 - Introduction to Operating Systems I took this with Professor Yuvraj who was an assisant Professor at the time and it was mainly being run by Professor Swift. I will not lie this is a super difficult class in terms of the time you need to commit to it. From my perspective when I took it the class was not super difficult to get an A in as long as you had tons of hours to pour into it because the projects were worth 50% of your entire grade and all the test cases were public for me. However, again the projects just take tons of time easily the class I've spent the most time on. Topics Covered: (look at OSTEP for more details) Virtualization Concurrency Persistence 544 - Big Data Systems I took this class when it was first offered as a 639 section and taught by Tyler Caraza-Harter and for it being the first time the course was ever offered it was structured and designed better than most of the other classes I've taken, the amount of work that was put into it was very evident. I'd reccomend this class to anyone who's interested in working on data engineering or any sort of data processing as it gives you a good fundamental understanding of many relevant and currently used technologies in the field and how they work at a lower level which you might not learn in as much detail on the job. This is definitely the class if you want hands on experience with a lot of actually industry relevant technologies, this is an amazing class for that and as a bonus you get some resume worthy projects and experience out of it. Topics Covered: PyTorch Docker RPC Hadoop Ecosystem Map Reduce HDFS Cassandra Spark Kafka Big Query & Big Table A Tier This tier I still would highly recommend taking if you like the topic or are interested in the field. 536 - Introduction to Programming Languages and Compilers I'm taking this class right now with Beck Hasti and I'm enjoying the class a lot, however I think there's a few things that could be changed with how the projects work to put this class into the S tier. The projects in my opinion skip over some of the interesting theoretical things talked about in class and instead use technologies that already do a lot of the work like jlex and jcup. The cool thing about the projects is that they build ontop of each other and you're building an entire compiler for a C-style language which is pretty cool to see come together from source code to assembly. Topics Covered: FSMs & Regular Expressions Context Free Grammars Syntax Directed Translation Parsing Top Down Bottom Up Predictive Parsing Static Semantic Analysis Name Analysis Type Checking Code Generation Optimization (no assignments on this section) 639 - CS Capstone This is a pretty interesting but relatively easy class where you get to work with a small group and get partnered up with a company or non profit and do a project for them. Getting mentorship and connections to these companies can be super valuable and especially if you find your project interesting it can be a great experience. I'd recommend that you sign up for this class with some friends that you know you can work well with. I personally built Orbit-IQ for The Union of Concerned Scientists. I also thought it was valuable to get experience understanding what the clients really want and how to communicate with non-technical people to get the information you need to build the project which is something that I think is super important in the real world and valuable to learn. Especially if you're looking for a class to take that will give you some experience working on a project that you can put on your resume I'd recommend this class as it's a great way to learn some technologies you might not work with in other classes and get some experience working with a team. B Tier For this tier, I would say that these are still probably worth taking, however I would suggest looking at taking a grad course instead of these if there are grad courses that are more interesting to you. 640 - Introduction to Computer Networks I'm taking this with Professor Suman and it definitely taught a good amount on how the internet works, although I think that the class felt more difficult than it needed to be as the quizzes were fairly difficult but I got the hang of it later on. If you're interested or like networks this is definitely a good class for you especially because Suman let groups of students instead of doing the homeworks to do a project on a topic of their choice as long as it interacted with networks in some way which seemed like a cool opportunity that many other classes wouldn't have given. The last project is working on implementing a simple version of TCP which I'm currently procrastinating on finishing by writing this blog post. There are probably better classes to take if you're not super interested in networks, I'd encourage people to consider taking a grad course on something they're more interested in if they're not super interested in networks. 564 - Database Management Systems I took this with AnHai Doan and he's a great lecturer although I don't know if enough material got covered in the class. I had come in with previous experience using SQL and relational databases (in addition to taking OS before this class) and in general and this class might be more beneficial to someone who hasn't had those experiences. However, there were still some interesting topics covered like: external sort, B+ trees, how logging is done in databases, and the ER model which I hadn't seen before but gives a good framework for communicating about database schemas. I do think that a lot of this class at least with AnHai could've been collapsed into a few days of self study and a project to apply the knowledge might've been more beneficial. For the final we were given a note sheet and to prove a point I collapsed every note I ever took into my 2 sided note sheet if you want to take a look. 502 - Theory and Practice in Computer Science Education I took this class with Andy Kuemmel and I did feel like it was an interesting class in terms of lecture material. It was only a single credit hour and I felt like I was doing more than a single credit hour of work for the class which was annoying. Andy seems to often change the structure of the class but when I took it we had: 1 hr of shelf peer mentoring hours, 1 hr class study group, avg of 0.5 hr of TA observation, and 50 minutes of lecture, and a brief reading and sometimes reflection on the reading each week. The semester after this one I'm aware that he had restructured it to be less of a time commitment. I personally would've found this class more interesting if it focused more on the content creation side of teaching and course design rather than the peer mentoring side of things. However, this was more on me for not understanding that this class was more so about improving the peer mentors and TAs who are teaching classes rather than how to teach or design a class yourself. In my opinion: I think that maybe if you're already going to be a TA or a peer mentor for a class this class might be beneficial to you and may provide an advantage if you're applying for those positions. However, if you're not going to be a TA or peer mentor I don't think this class is worth the time commitment. If there was a class that was more focused on the content creation side of teaching and course design I would be interested in taking that class. C Tier 577 - Introduction to Algorithms I took this with Professor Renault and I like him as a person, but the lectures were very much powerpoint slides and I didn't feel like I was learning much from them. However, I did feel like since I was applying to jobs at the time I did feel that my ability to do Leetcode problems did improve although I'm not sure how much of that was from the class and how much was from me just doing Leetcode problems. Note: You still should take this course, it's just not as interesting as the other courses in the other tiers and I didn't like it too much. D Tier I'd consider avoiding these classes if you can, however if you're interested in the topic or if it's a pre-req for a class you want to take I'd still consider taking it. 540 - Introduction to Artificial Intelligence This is also a super professor dependent class and I've heard great thing about Fred's version of the class so I'd recommend taking it with him if you can. If you're interested in doing AI this isn't a bad course to take for survey detail, however I took it when Jerry Zhu with my lecturer being Yudong Chen. I've heard this is better with other professors. I personally don't think I had many good takeaways from the class other than a few refreshers in linear algebra and statistics. The homeworks were not at all related to any of the contnet we've learned in class as no programming was covered in lecture and the lectures were all theory based. The homeworks were all programming heavy and a lot of the libraries we were using felt like an entirely new language and the averages on the project were super easily done by AI boosting the grade averages which meant that the only thing that mattered was the midterm and final grade. Which was annoying because the midterm and final focused entirely on the theory taught in lecture which we didn't have any practice with in the homeworks or other assignments. I could see this being more valuable for people who (1) plan to do AI and (2) don't know anything about AI yet. I personally felt like I didn't want to do AI before taking the class and I did feel like I was already trying to understand AI and it in the news so a lot of the content that I did understand wasn't new to me. 639 - Parallel and High Throughput Programming Oh, where do I even start. I'm writing this in the class right now. The professor is constantly showing up to class 5 minutes late, the lectures feel like line by line code walkthroughs, and the projects feel like busy work. I feel like this class has interesting takeaways maybe like once a week, this class maybe can be more interesting to you if you like simulations or graphics as the professor is super knowledgeable in the field however this wasn't my interest and you might gt more out of his office hours. Most of the class focuses on matrix operation optimizations which seems more directly relevant to those use cases than what I'd be interested in. However, I feel like if you care about those you should take the grad level HPC course instead of this one as I've heard that one is more interesting and more beneficial. The projects feel like they're just busy work and I'm not learning much from them. There was a single project where I feel like I learned anything and that one we had to implement and improve these different functions/kernels using some of the techniques we learned in class which was a good project. However a significant amount of the projects are just "hey here's this code on our git repo for the class, can you compile it then run it and tweak like a parameter or two and write a report on what the difference was?". Sometimes if we were lucky the project would be just read the documentation for this function and get it to do this thing differently then run it, tweak parameters, and report the run time. In my opinion, if a project is just "run this code and write a report on it" it's not a good project. Projects should be about implementing things you've learned in class or trying to use at least some mental effort to solve a problem that will reinforce your learnings in class. They should challenge you at least a little bit to try to apply what you've learned in class, which these "benchmarking" projects don't do. This is the exact sort of class that I would've dropped if I had the chance to do it over again. I don't feel like I'm learning much from the class and I feel like I'm just doing busy work. It's the exact type of class that the 639 number was made for trialing out classes before they're official. The professor says that this class will become an official cataloged class soon and I hope that when it does it gets restructured to be more beneficial to the students taking it. Like one easy improvement that could get people more involved is making the projects more difficult and maybe more like "here's a problem, here's some code that does something similar, can you make this faster using the techniques we learned in class?". And for student engagement you could have students upload it to Gradescope and enable Gradescope's leaderboard feature for speed of the code like how 577 does it with the coding assignments would easily engage people more in the class and get them to learn more and care more about the projects for not much more effort on the professor's part. This wouldn't fix everything about the class but it would at least make it feel more engaging and like you're learning something from the projects. Entrepreneurship Courses I decided to do the entrepreneurship certificate because I thought it would be interesting and I wanted to learn more about the business side of things especially in the tech industry. I think that the certificate could be valuable as long as you intentionally take the right classes and get the right experiences out of it. However, I think that I didn't pick the optimal ones for me so here's the ones I took and my thoughts on them. Also do not be afraid to take classes that don't count towards the certificate if you think they'll be beneficial to you or if it's a pre-req for another class on the list. S Tier None 💀 A Tier Marketing 365 - Technology Product Marketing I'm in this right now and it's pretty interesting. The professor is knowledgeable and the class is structured well. I definitely feel like I've learned a lot about more of the business side of the tech industry and how they market their products. I think this class is valuable if you're interested in working in the tech industry and want to learn more about how they market their products. B Tier Marketing 300 - Marketing Management I thought this was a good class on the basics of marketing. I think it's a good class to take if you're interested in learning more about marketing and if you're intereted in potentially creating your own product in the future you'll need to market it and having the fundamentals of marketing down will be beneficial. MHR 322 - Introduction to Entrepreneurship I took this class quite awhile ago so I don't remember much about it. I do remember that it was a fair amount of good information about how to start a business and the different things you should to do to get started like making a business plan, product market fit, etc. The main project focuses around designing and selling a T-shirt in a group, but I didn't like this part of the class. C Tier Econ 101 - Principles of Microeconomics It was fine, I mean it's econ 101. I can't really say much about it. I'd only take this if you want to take more classes later on that require it as a pre-req like Marketing 300. D Tier Gen Bus 310 - Fundamentals of Accounting and Finance for Non-Business Majors I took this class online and I didn't really like it. The recorded lectures are a little bit old and the professor comes off as super condescending in them with jokes like "I know this is an online class and you might've taken it to slack off but my class is not one you can slack off in". I just didn't like the tone and it felt like a lot of the content was just memorizing or "I got ya" sort of questions which I don't think is a good way to teach a class or structure exams. However the professor when I took it did a outside of class personal finance and investing seminar sort of thing that might've been literately the most valuable use of my time in college. This is completely unrelated to the class and he doesn't get paid for it, and if you can find out the time and place for it I'd recommend going to it. It's a brief crash course on personal finance and investing and it's super valuable information that I think everyone should know. Gen Bus 311 - Fundamentals of Management and Marketing for Non-Business Majors It's not entirely this class's fault but I took it online. It was too easy, I don't remember anything from it. It seemed like a lot of content repeat from MHR 322 & Gen Bus 310 to the point where I felt like I was wasting my time. Gen Eds Note: I took a lot of these online over covid so they might've changed significantly since I took them. S Tier Afro Amer 154 - Hip-Hop and Contemporary American Society This is definitely by far my favorite Gen Ed that I've taken here. I took it with Professor Shashko and he is super knowledgable and a great lecturer. I personally found the class super interesting as you learn about the history of hip hop and do some readings on it. For the final paper you get to pick a year and write about the top 3 impactful things you think happened in hip hop that year and justify it. Any class where you can get almost a perfect score on the final paper writing about: The Travis Scott McDonald Meal and Hamilton is a pretty good class in my opinion. Lit Trans 276 - Special Topics in German and World Literature (German Folklore) I think the Professor teaching this job hopped somewhere else but I thought this class was pretty interesting and relatively easy. We got to read a lot of fairy tales and it was interesting to analyze and make a small little presentation on them for the final project. Comm Arts 355 - Introduction to Media Production Ok first off, I would not take this course as a gen ed if you're not already interested in media production or just want the credit. I took this course because I was interested in learning more about video production and I thought it was a great class for that although pretty intense. I definitely got some subpar group members which made the class a lot more difficult than it needed to be. But definitely interesting and I learned a lot about video production and editing. A Tier Anthro 105 - Principles of Biological Anthropology This one is where you learn about the evolution of humans and get to do some cool online labs of like analyzing skulls and other bones to try to determine what species they are. I thought it was pretty interesting of a class and opened my eyes to some of the things that are studied in anthropology. Genetics 133 - Genetics in the News I feel like if I wasn't in CS I would've at least considered majoring in genetics since it's always seemed super interesting to me. This class is great for people who are interested in genetics and want some foundational knowledge about it that can help them understand the news better and discuss current events and news in genetics. Music 113 - Music in Performance / Clap for Credit The one, the only clap for credit. Great if you're looking for an easy A and need to hit some credit requirements. I think the only con to this is that it's a 1 credit class but takes up a good amount of time in your schedule as it's just something else you have to do. B Tier Astron 103 - The Evolving Universe: Stars, Galaxies, and Cosmology Was interesting, although at least somewhat fairly difficult. It definitely had interesting content and does make you feel quite small in the grand scheme of things, if you're interested in space it's good. C Tier Comm Arts 100 - Introduction to Speech Composition I took this online and I didn't like it. I felt like the content was pretty basic and I didn't feel like I learned much from it. My Full Semesterly Schedules These are just all the semesters I've taken and the classes I've taken so hopefully you can get an idea of how difficult your schedule might be :D Fall 2020: ILS 138, Math 221, CS 300, Comm Arts 100, Anthro 105 Spring 2021: Math 222, CS 400, CS 252, Genetics 133 Fall 2021: MHR 322, Astron 103, CS 354, CS 240, Afro Amer 154 Spring 2022: Math 340, Littrans 276 (german folklore), Gen Bus 311, CS 537 Fall 2022: Gen bus 310, Engl 140, CS 577, Stat 324 Spring 2023: Comm Arts 355, Music 113, Econ 101, CS 639 (Big Data now CS 544), CS 642 Summer 2023: Music 113 Fall 2023: CS 564, CS 540, Marketing 300, CS 639 (Capstone), CS 502 Spring 2024: CS 640, CS 536, Marketing 365 (Technology product marketing), CS 639 (Parallel and High Throughput Programming)

GitHub Field Day NYC 2024 Organizer

GitHub Field Day NYC 2024 Organizer 3/15/2024

I had the pleasure of helping organize GitHub Field Day NYC 2024, and it took a lot of planning and coordination to make it happen. I had a lot of fun at the event and wanted to detail some of the things that went into organizing it and some parts of the event that I found interesting. What Is GitHub Field Day? It was my first time attending a GitHub Field Day event and at first I was a little confused what it was all about. So I wanted to provide a little context for those who aren't familiar with the event and hopefully it will help you decide if you want to attend one in the future. GitHub Field Day is an unconference event that is organized by your fellow students who are a part of the GitHub Campus Experts program. An unconference is a conference without any topics set in advance and instead it is all participant-driven, meaning that the attendees decide what they want to talk about with each other. This is a great way to meet new people and learn from others from different backgrounds and experiences and get some fresh perspectives on topics that interest you. It's primarily an event that focuses on student community leaders and what you can learn from other student leaders to improve your own community and make it more inclusive and welcoming to all students. It's a great way to meet other students who are passionate about technology and building communities and to learn from their experiences and share your own. The Process In this section I'll cover what we had to do on the organizing team to make the event happen and some of the challenges we faced along the way. Initial Planning The cool thing about GitHub Field Day is that it is organized by students who are a part of the GitHub Campus Experts program, so the GitHub team gives you a lot of freedom to plan the event how you want, with some constraints of course. This is definitely a double edged sword because it means you have to do a lot of the planning and coordination yourself, but it also means you can make the event your own and do what you think is best. We started planning the event almost a year in advance and in the summer we decided on a location and rough time frame. We decided to run the event in Fall 2023 in Seattle. One of the first things GitHub wants from the organizing team is a budget for the event and a rough idea of how many people will attend. This is also the step where you decide on a where your money will go as GitHub gives a maximum of 100 USD per attendee. We decided to spend most of the budget on both food and drinks and then travel reimbursements for attendees who needed it. Getting A Venue The biggest challenge we faced was finding a venue, luckily the Microsoft offices often are kind enough to let us use their space for free. This is a huge help as it can be super expensive to rent a venue for a day in any city and would have eaten up a lot of our budget. This is the step that is the most frustrating, as it can take a long time for the GitHub team to find the correct person to talk to at Microsoft and then for them to approve the event. Unfortunately, we had to wait too long for Microsoft to approve the Seattle event and we had to delay it, but I'll talk more about that later. Getting Attendees As mentioned above, we didn't have much time to get attendees to the event, but we tried and we emailed a lot of student leaders, deans, and professors to try to get the word out around Seattle. We also posted on social media and tried to get the word out to as many people as possible. Unfortunately, we didn't get enough applicants to run the event in Seattle, so we decided to push it back and move it to New York City to reach a larger audience. Location Change This is sort of the same time frame for when I started to get busy and burned out of working on the event for the last ~5 months. Then for this new location change we had to go through the same steps again, but this time we got approved by Microsoft much faster and we were able to get the event up and running in NYC. The Event For my first time attending a GitHub Field Day event, I really liked the unconference format of the event, as it was a great way to meet new people and learn from others. I liked that the attendees got to decide what they wanted to talk about and that it was all participant-driven. I also liked that the event was focused on student community leaders and that it was a great way to learn from others and share your own experiences. Pre-Ceremony Before the opening ceremony, we had a little bit of time for us to meet other attendees and for other attendees to meet each other. We had our food ready for people to eat and we had some music playing in the background to set the mood for the event. We also ran a little fun game of rock paper scissors where it's a contest style where if you lose you're eliminated but the fun part is if you lose you have to cheer on the person who beat you and then you can join their team and cheer them on for the rest of the game. This was a great way to get people to meet each other and start talking to each other and it was a lot of fun. Opening Ceremony The opening ceremony we started off with an interesting keynote presentation by Jon Gottfried, who is a co-founder of Major League Hacking. He talked about his experiences building communities and what he has learned from them. He also talked about the importance of building inclusive communities and how you can make your community more welcoming to all students. My favorite part of his keynote was about how he participated in this Hackbus event where attendees register to go on a bus ride to a secret location and then when they arrive at the bus they all get told where the bus is driving and they have to plan their entire trip on the bus from: hotel rooms, food, and to make it even more interesting they have to build a hackathon project on the bus in addition to planning all the rules and judging around how to judge the projects. This was a great way to get people to work together and build a community and I thought it was a great idea. It seems absurd but it also seems like a super cool experience. After the keynote, we started doing some audience activities to get people to meet each other and start talking about what they wanted to talk about during the rest of the day. My favorite part of this was a snow-ball activity where we asked all the attendees to write down some information about themselves on a piece of paper including why they were at the event and what they wanted to gain from the event, then we threw them all around the room and we read some of them out loud as a way to get attendees to feel like everyone else is also there for similiar reasons. !Snowball Activity We then had all the attendees pick one thing that they're interested in talking about and write it on a sticky note which we put on the wall then we started grouping like topics together and developed what our different sessions would be about for the rest of the day based on the sticky notes. Some Topics Some of the topics that I remember that got covered during the event session were: Hackathons 101 & 201 How to plan your first event How to get sponsors for your event How to get internships How to make your community more inclusive Miscellaneous topics like: robotics, open source projects, etc. And many more that I'm forgetting Some Interesting Conversations One of my most interesting conversations in my opinion was about how to make a community around developing open source projects. I'll just list some interesting ideas that were brought up during the conversation: A mini-hackathon, where the day before everyone submits ideas for projects that can are finishable in a few hours and the organizing team filters down the list to what's feasible and then attendees in groups of 2-4 people can pick a project to work on and then present it at the end of the day. The idea is that each team will also have a mentor who can help them with their project and gives them guidance on how to finish the project and good coding practices. This can also be modified to where everyone works on the same feature or project but everyone has different implementations and then at the end of the day everyone can see how different people solved the same problem. Open Source Shared Project, this is one type of event that I'm really interested in hosting. The idea is that you have a shared project that everyone can work on and contribute to, and during these events you get small groups of people together to work on a specific feature or bug fix and then at the end of the day you have a lot of people who have contributed to the project and can see the progress that has been made in a short amount of time. Ideally for this one to you'd have a handful of people who know the project well and can help guide the new contributors on their team and help them get started with figuring out how to contribute to the project, since it's hard to start contributing to a larger project or codebase that you're not familiar with is also not a skill that is taught in school. I think this is a great way to get people to start contributing to open source projects and to get them to see how they can make a difference in a project that they care about. If I decide to run this type of event, I think I might try it for ApplicantAtlas but this could be easily modified to work with any open source project that the attendees are interested in contributing to. Conclusion Overall, I had a great time at GitHub Field Day NYC 2024 and I learned a lot from the other attendees and the sessions that I attended. I think it's a great event for student community leaders to learn from others and share their own experiences and I would definitely recommend it to others who are interested in building communities and making them more inclusive and welcoming to all students. It's also super refreshing and inspiring to meet new people that are just as passionate about technology and building communities as you are and to learn from their experiences and share your own. I think it's a great way to get new ideas and perspectives on how to improve your own community and make it more welcoming to all students. Photo Gallery !#1 !#2 !#3 !#4 !#5 !#6 !#7

Battlecode 2024 Finalist

Battlecode 2024 Finalist 1/28/2024

I was dragged into Battlecode 2024 by one of our teammates. I had never heard of Battlecode before, but I was excited to try it out. I had a lot of fun and I'm glad I did it, and we ended up qualifying for the finals and placing 13th overall. So I figured I'd write a blog post about the experience from the perspective of a first time participant. What is Battlecode? Battlecode is a contest where you write code to control a team of robots that have to accomplish some task. You can read more about it here. This year the game was a duck based capture the flag game where our goal was to capture all 3 of the flags from the opponent. The game is played on a grid and each team has a base where they spawn ducks. Ducks can move around the map, build traps, and attack other ducks. The game is played in rounds, and each round the ducks are given a set amount of bytecode to execute their actions. Here's a quick snippet of what the game looks like. !Battlecode 24 There's a lot going on in that gif so let's break it down a little bit. Duck Actions Each duck has a few actions to help attack or defend flags that it can perform each turn/round (shown at the bottom of the gif above). Each action has a specific cooldown so you can't just spam the same action over and over again. Move to a new tile Build traps: water, bombs, stuns, dig a water pit, and fill a water pit Pick up flag Attack an enemy duck Heal Respawn When a duck dies, it can respawn at one of the team's spawn points after ~20 rounds Crumbs There's also a currency called crumbs that you can get from two ways: a few spawn on the map each round which you can pick up, and you also get some for killing enemy ducks in their territory. Actions that build traps require crumbs, which requires you to be strategic about how you use your crumbs. Why It's Difficult Since the same code gets deployed to all the ducks, you have to write code that can handle a lot of different situations. Maybe you want some ducks to focus on defending and building around base, maybe you want some designated to go out and capture flags, and maybe you want some to be aggressive and attack the enemy ducks. A few things that make it difficult: There's a limited size shared array that each duck can read and write This is the only way to communicate information between your ducks about the state of the game This means you have to be strategic about what information you store in the array and how you use it, and if you have all your ducks performing the same action based on the same information you have to be careful because otherwise they'll cluster up doing the same thing so you have to be careful about how you distribute the work Each duck is given 25K bytecode to execute per turn This means that each turn each duck gets to execute a certain number of actions, calculations, and memory reads and writes. If you want super good pathfinding (which we didn't have) you have to be careful about how you use your bytecode in intensive calculations like this otherwise you'll run out of bytecode and your ducks will just sit there and do nothing Luckily we didn't have to worry about this too much since 25K is quite large and apparently in previous years its been much smaller I also feel like it's really hard to tell if your new bot is better than the previous version, like usually it's better in some situations and worse in others. Unlike most software I'm used to working on it's easy to tell if what you've made is better than before since if you added a new feature it's better than before. For this I'd say like at least half of the features I tried to develop didn't work super well and just ended up scrapping the changes. There's so many branches for dead features that just didn't work out. The Contest Structure Ok so now that we have a basic understanding of the game, let's talk about the actual competition. Leaderboard The leaderboard is one of the most important parts of the contest. It's a semi-live leaderboard that shows the rankings of all the teams in the contest. Every 4 hours there would be ranked games played against your relative neighbors on the leaderboard and if you win you gain more points and if you lose you lose points. Furthermore, you can manually queue your own ranked games against other teams as long as they allow it. This is important because you can't just queue games against the same team over and over again to farm points. However, you can also queue unranked games against any team which is important for testing your bot against other teams to see if the changes you made are actually better than before against real opponents. Sprints Sprints are a separate part of the contest where the organizers run a bracket of games and livestream the results. Sprints are played across all teams whether they're in your division or not. The sprints are a fun way to see how your bot is doing against other teams and it's also a good way to see how the other teams are doing. The seeding of your team in the sprints is based on your leaderboard ranking, so if you're doing well in the leaderboard you'll be seeded higher in the sprints. Tournaments Tournaments are also livestreamed and are played across the teams in your divison in the same way as the sprints. The seeding of your team in the tournaments is based on your leaderboard ranking, so if you're doing well in the leaderboard you'll be seeded higher in the tournaments. In our year the top 12 US college teams and the top 4 international teams qualified for the finals. In addition there's other divisions like high school and new to battlecode teams that have their own tournament. Our Robot Ok now that we know more about what battlecode is and how the contest is structured, let's talk about our robot and some of the strategies we used. This section is going to be a little bit blurry because I'm writing this ~2 months after the contest and I don't remember everything we did. Our Strategies We had a few different strategies and variations of our bot across the tournament that we tried out especially as the game got tweaked for balance and we learned more about the game. Setup Phase For the first 200 out of the 250 rounds of setup we just had all of our ducks move around randomly to try to explore as much of it as we could After that we had our ducks move to the center of the map and build traps next to the wall dividing the two sides of the map Base Defense We had designated ducks that would stay at all times guarding our flags and building traps around our base and especially right on the flag itself which we placed down bombs and stun traps right on the flag so that if the enemy tried to pick it up they would get stunned and we could attack them. We also decided to make a water moat checkboard grid pattern around our flags so that the enemy ducks would either have to spend crumbs trying to fill the water or go through on the diagonals which made sure that the enemy ducks couldnt completely swarm our base at once and it made them funnel through a few paths which made it easier for our ducks to defend. If a duck was guarding the flag and it saw an enemy duck nearby it would set a global variable in the shared array that would call other ducks to come help defend the flag. We also made sure that if these defense points were called that we would prefer ducks to spawn nearby to help defend the flag. But we had to be careful about this because if we called too many ducks to defend the flag then we wouldn't have enough ducks to go out and capture the enemy flags. Flag Passing We noticed that often our bots would get stuck surrounding the duck with the flag and preventing it from really moving anywhere so we implemented a flag passing strategy where it would pass the flag to another duck closer to where the flag needed to be captured We added this pretty late in the tournament and it worked pretty well. Flag Return When a duck was returning the flag we had logic to assign nearby ducks to escort the duck returning the flag to make sure that it could get back to our base safely It also targeted to return to the base that was closest to where the flag carrier was Things To Improve Pathfinding We took code from a previous year's bot for doing BugNav pathfinding but in their year the bytecode limit was much smaller so we had a lot more bytecode that we could've been using to do smarter pathfinding but didn't move to something better. Our pathfinding was so bad that in the sprints we would often get stuck trying to return the flag and often lost games because of it and the casters would make fun of us for it 😭 but it was funny so I didn't mind Better Distribution of Specializations One thing I didn't mention was that when a duck does an action enough times it'll specialize in that action and get more efficient at it. This specialization also limits it's peak efficiency in other actions so we should've probably been more careful about this since for a lot of the tournament most of our ducks were specialized in healing and we didn't really need that many ducks specialized in healing since it made us worse at fighting. I did make this a little bit more well balanced between healers and fighters at the end but I think this is something we should've done in a more calculated way to try to maximize the most out of our ducks Stuck Flag Duck We just didn't write any code to handle the case where a duck picks up the enemy flag and gets stuck somewhere like on an island surrounded by water and were just too lazy to fix it and it didn't happen often enough for us to care about it too much. Duck Standoff Sometimes our ducks would just sit there and do nothing and not move because both groups of ducks calculated that they were at a disadvantage and that they shouldn't be aggressive which was annoying and we didn't really have a good way to handle this. Moving Flags We tried to move the flags around the map in setup which lets you change the location where your flags are but we didn't invest enough time into this for it to be super effective. Other teams were able to move their flags around the map in more effective ways. Especially when they were scoring spots of the map based on things like the # of walls around the flag and the distance away from friendly spawns and enemy spawns. This is definitely a feature that we should've spent more time on since it was pretty effective for other teams You can find our code here Qualifying I just thought this would be fun to include but to qualify for the finals we had to win this match and we were pretty excited when we did. Here's a video of us winning the match ![Winning the match](https://www.youtube.com/watch?v=-2-E2DP2t6A) The Finals This section is more dedicated to our experience in Boston for the finals, which was pretty amazing but if you want to skip this segment and go to reflection that's cool too. The Experience The finals were held at MIT in Boston, and we all got flown out there for the event and it was my first time in memory being in Boston and the city was really pretty. We also ended up staying in the MIT dorms which was exciting because of the other people we met there through being in the dorms. Although, if I were to do it again I would've probably stayed in a hotel because the dorms are well ya know college dorms and could've been cleaner and I could've had a comfortable bed. We also all were invited to a dinner before the finals where we got to meet the other teams and the organizers. It was interesting to see where everyone was from in addition we got some really nice food from them for the dinner. The Results The finals was hosted in their auditorium and was pretty fun to watch even if we went 0-2, but we did place 13th overall and it was already a huge accomplishment to make it this far. Also they ran a estimathon where we had to guess a range on some question and I ended up winning a duck from correctly estimating the number of MIT dorm residents that offered to host teams for the finals. Here's a video of me catching the duck: !Duck Catching Fun fact is that I put a notebook under my jacket when I before I went walking up there so the video looks kinda silly because of how I'm walking 😭 If you want to watch any part of the finals they've uploaded the Battlecode 2024 Finals to YouTube Reflection I'm definitely not an expert on Battlecode, but I do have a few key takeaways from the experience and things I'd improve on if I were to do it again. Invest Time in Writing Organized and Clean Code Even though that it initially might seem like a fairly simple game even in a year where our game was relatively simple compared to other years it's criticial to invest a lot of time in writing organized and clean code. We didn't do code reviews, and didn't refactor our code as much as we should've and it ended up biting us throughout the rest of the tournament as we had to fix bugs and just try to understand what our code was doing. This is something that I would suggest everyone invests more time in especially at the beginning to set up a good foundation and structure for your project so that you can build on it and make changes more easily. Part of the reason we didn't do this is because we felt we were rushed to get features out for the sprints to see how we were doing against everyone else and wanted our games to be shown on the stream. Sprints Aren't Everything This brings us into the next point that sprints aren't everything and don't matter too much. You definitely should focus on the main event itself and not getting too caught up in making your bot perfect for the sprints. In addition, if you don't end up making it that far in the sprints it's not the end of the world. We never got our games shown on the sprint stream and certaintly didn't win them. At least our year it felt like the bracket we were in (US college) was relatively small and if you don't end up making it super far in the sprint it's not over for your team and you can still qualify for the finals. Scrimmage a Lot As I mentioned earlier, it's super difficult to tell if your new bot is better than the previous version since you can only locally test your bot against other variants of code that you have and in a lot of cases it's not super helpful to test against your previous versions of your bot because if they're too similiar they'll often draw a lot or you'll see that the change you made is better in some situations and worse in others. This is why it's important to scrimmage a lot of other teams to see if your changes are actually better than before against real opponents that you'll likely face in ranked games and the tournaments. It didn't cross my mind until the end of the tournament when another team shared that they did this, but I think it's a really good idea to make a script to automatically queue games against other teams and with some sort of evaluation to see if your changes are actually better than before. One script is linked here Even if you don't have a script to automatically do this, it's still important to manually queue games against other teams to see if your changes are actually better than before with the changes you made. We didn't and we still queued 818 total unranked scrimmaged which is the 8th most of any team. And 7th most total scrimmages with 1,294 in total. Watch Your Games One of the downsides to an automated script to queue games is that you probably wouldn't be watching your games as often. It's super valuable to watch the games that you're playing to see what situations your bot is doing well in and what situations it's doing poorly in. This gives you a lot of information about what you can potentially do to improve your bot and your strategies. Watch the Other Teams It's also equally important to watch the other teams games (especially if they have auto scrimmages off) to see what strategies they're using and how their bot is doing. If you see a team that's doing much better than you or you see some interesting strategies that they're using, don't be afraid to steal and augment their strategies to fit your bot potentially even better than how they're using it. Use Community Resources The Battlecode community is super helpful and there's a lot of resources out there to help you get started and improve your bot. There's a lot of teams that have shared their code and strategies from previous years and it's a great way to get started and see what other teams are doing. In addition there's a lot of code from previous years that also works every year and is a great way to get started and see what other teams are doing. For example: shared array communication, pathfinding, etc. All of these are things that you can find in previous years code and use in your bot. Advice to New Participants It can be overwhelming to get started with Battlecode because there's a lot of things to learn about: the game specifications, the contest structure, strategies, limitations on the game, how to communicate between your ducks, running games locally, etc. Not to mention that it can be difficult to start writing code because you have to get used to what methods exist and what actions you can perform and what information you can and cannot access and can be difficult to work with. I definitely highly suggest that you use an IDE with lots of autocomplete so you can preview all available methods. It feels a lot like working with a library like Pandas where there's a lot of methods and you have to get used to what's available and sort of feels like another language entirely. It definitely frustrated me at the start because I just wanted to add some basic features but as a combination of: our project not being super organized, me not being familiar with the game, or how to write code for it, it was quite annoying to get started. But it's worth it to push through and get started because it's a lot of fun and you'll learn a lot. Photo Gallery Here's a few photos from our trip: !Battlecode 24 !Battlecode 24 !Battlecode 24 !Battlecode 24 !Battlecode 24 !Battlecode 24 !Battlecode 24 !Battlecode 24 I had a lot of fun and I'm glad I ended up participating. I hope this post was helpful to anyone who's considering participating in Battlecode in the future and hope you have a great time if you do end up participating. And thanks to the Battlecode organizers for putting on a great event!

Organizing MadHacks Fall 2023 Reflections

Organizing MadHacks Fall 2023 Reflections 11/11/2023

I was one of the lead organizers for MadHacks Fall 2023, a 24-hour hackathon at the University of Wisconsin-Madison. The amount of effort and time that went into planning and executing this was absurd, so I wanted to write a blog post about it and hopefully inspire others to organize more events like this, but hopefully with less stress and better tools and advice for the job. I might be out of the hackathon organizing scene now, but if you've organized hackathons and have advice I'd definitely write a blog post of your own about everything you learned so that others can learn from it :D My Role I was unofficially the lead organizer of the event and did pretty much everything except for: judging plans (thanks Sam), day-of event logistics, catering, and taxes (thanks Grace). However, I did: Finding sponsors Updating the website Designing and ordering swag and banner Marketing Planning the workshops Social media Coordinating to reserve space Attempting to make a photo booth Event Applications Probably more that I'm forgetting The Planning In this section I'll try to break down the planning and execution of the event into different segments by the different segments of planning. Getting a Venue Luckily we get venue for free since we're a school organization. So I'm not going to comment on it too much. What I would do differently: Finalize the venue and dates earlier since this blocks sponsorship confirmation and outreach We used the educational sciences block, but this does limit our capacity as a hackathon as the space is large although not huge. Having more individual rooms for hackers to go into with their team would be nice instead of like just one huge lecture hall Getting Sponsorship I was the main person to reach out to sponsors and to get them to give money, swag, or discounts to the event. What I did: I mainly used my LinkedIn premium messages to reach out to companies employees and try to get the direct email of who is in charge of sponsorships at companies that had already sponsored MadHacks before, or other hackathons on Devpost, and just local companies around Madison. Honestly this was a bit of a nightmare and a grind to get companies to both respond to me and actually be interested in sponsoring. We ended up sending out more than 125 total messages to get in total 9 sponsors, of which 1 was a local company that was growing (Fetch Rewards), 1 had sponsored before (Epic Systems), 3 were almost guaranteed to sponsor (MLH, GitHub through GitHub Education, and AWS Cloud Clubs), 1 was our school, 1 was a company that gave us discount through MLH (StandOut Stickers), and 2 were non donating clubs/orgs that were running workshops (Girls Who Code, and UPL which organized the event). So in total we got like ~$7,000 in directly from sponsor outreach, luckily we had ~6-7k as left over from previous events. Otherwise, we would have been in a bit of a pickle. What I learned: It's a grind to get companies to sponsor, it probably would've taken less time to just get all organizers to freelance for a few hours and then just donate the money to the event 😭 LinkedIn probably isn't the best way to do this, I have LinkedIn premium for free so I thought it would be a good idea but I think it's mostly a waste of time. You might as well try to reach out to food/drink companies to see if they're willing to give products to the event. I reached out to Bubblr which from what I understand is somewhat of a joint venture with Pepsi, and our school is a Pepsi marketing campus so I reached out. They had a form on their website and with like 2 weeks notice I had 500 cans of Bubblr for 300 person evnet. You might as well reach out to food companies, like I reached out to Culvers and Kwik Trip and a few others but nothing came of it however I think since the drinks were a success it would've been worth it to research and email a few more food companies not over LinkedIn It's important to have some tracking software for who you've reached out to and who has responded, I used a Google Sheet and it was a bit of a mess but it worked. Having different variants of templates of emails for everyone to send out worked well as some people didn't have experience reaching out to companies and it was a good way to get them started. Putting company sponsors on the website is beneficial to the companies! I had someone reach out to me that they got an internship after applying to one of our sponsors and that they wouldn't have applied if it wasn't for the sponsorship. What I would do differently: I attempted to hand over some of the sponsorship outreach to others however I think partially because a lot of the work took place over the summer a lot of people didn't do at least as much as I did on this. Giving people more of a specific quota of companies to reach out to might've helped. Use Email not LinkedIn I haven't tried but MLH said that hunter.io works pretty good and given a company's website it knows the email pattern that company uses so if you know the name of the person you want to reach out to you can probably guess their email, which I had through LinkedIn. Templating/versioning emails based on who I was sending it to Some MLH coaches suggested mail merge for this, I think that would've been a good idea. Making emails more brief & generalized Instead of like having to explain a hackathon and everything like that, I could've just been more general and said like "I'm hosting an event at UW-Madison with 300+ applicants and X% are seniors and I see that you have a lot of job openings for seniors and I think it would be a great opportunity for you to reach out to them" or something like that. Since finding the right person is so difficult I think it would've been worth it to reach out to some non-competing hackathosn to see if they would be willing to share the email of their sponsor's representative. Email Opening Rate It would be worth to invest into some software to tell if recipients opened your email or not to optimize the template further. If we had a low opening rate we could try to change the subject line or the first few sentences to try to get more people to open the email. Ok that's probably the longest section of this blog post, I'll try to keep the rest of the sections shorter. Marketing Luckily for this event we were reusing the same graphics and branding that someone the previous semester made because nobody wanted to design new graphics and I wasn't going to make an entirely new design for the event because I was already too busy so we kept with the same design. What I did Updated branding on older accounts that were lost from pre-covid like Instagram and LinkedIn and Twitter Updated website with new sponsors and new information Made announcements about applications through social media, our school's newsletter, and through a few Discord servers that organizers had connections to. We attended school org fairs and handed out stickers and flyers to get people to apply MLH this year around had target application threshold perks where if you got 80% and 100% of your target number of applications (2x expected capacity) you'd get 1 free perk from them if you reached these thresholds each. So we were marketing it pretty hard and trying to reach these targets. Designed & Ordered a backdrop banner with company logos for people to take photos against Idea with this was to create something that companies would consider a nice perk of having contestands share images with their logo on social media afterwards. Also see the photo booth segment which is also marketing What I learned: What we worked did pretty well, I think because of how large of a presence the UPL which was most of the organizers had on campus especially in the first few weeks where a lot of freshman and people coming to explore the UPL we had a lot of people interested We closed applications ~a month before the event was to be hosted if I remember correctly, we might've wanted to do this earlier if it wasn't for the threshold we were trying to reach. LinkedIn was good I think especially for post event as people could tag the account and it shows external sponsors our significance on another platform that recruiters might be more familiar with. My plan with the social media was not for it to pay off for this hackathon, but I think having a bigger presence with social media will help in the future for getting sponsors and applicants and just making the community more engaged. I think this is not something that should be neglected What I would do differently: Honestly it went pretty well I think this went great I would maybe open applications like a week or two earlier, but we were stalled on finding specific dates However maybe just send out applications form regardless earlier but just say TBA on the date Ideas For Getting More Applicants We considered potentially partnering with another hackathon in our region and buying a bus to bring their students to us and back with the agreement that they'd do the same for their hackathon but never got around to this. Not sure if we neccessairly want or should do this but we could've advertised through the Madison school district better and got more high-school students. I'm bias because I attendeed a hackathon that made me sure I wanted to do CS in hackathon, but it was run by high schoolers. Probably could've targeted other Madison colleges better like Edgewood, MATC, College of Madison, etc. Would've been nice to give at least some travel reimbursement but no money, would've helped bring in people at least from like Milwaukee. For overnight guests, when I went to MIT for Battlecode 2024 they have a university wide program that lets and incentivizes people travelling to MIT for a competition they'll match students who live in dorms to host these students. Most of the time it's not paid for the host but when I did it, it was. This could be something interesting to explore, although it really just depends if the university would allow this, but the university might allow it since we have MIT as a case example. Applications This is about sort of the internal hidden application process which was not fun and super annoying. What I did: I decided to use tally.so since the previous semester used it and it would be easy to just copy and paste the form with conditional logic and slightly modify it to use it this year. We specifically improved the form by requiring people under 18 at time of the event to fill out the form in their application step which saved a lot of time over the previous semester. We decided we needed to send out confirmation emails when someone applied because in the previous semester not doing this casued a lot of issues Tally did not provide this functionality in their free tier but they did webhooks on submission with the entire content of the submission so I created a lambda function to use AWS's SQS to send confirmation messages out Since we opened applications a little late this part was kinda a nightmare, I decided I wanted people to still be able to apply while sending out different "waves" of acceptances/RSVPs I had like a folder with 50 files of csvs and scripts all trying to cross join between applicants and trying to mark if an attendee's RSVP had expired since there was no protection on the RSVP form this was all done through a lot of tedious scripts. This would not have been as much of a nightmare if we had closed applications before RSVP, although still wouldn't have been a clean process Used AWS SQS to send out emails in bulk for RSVPs, reminders, day of logistics, etc. Used people's phone number as a key to join against entries What I learned: AWS SQS Generally Works We did see some temporary email withholding by UW Madion's IT Team because of the volume of emails we were sending out. If I remember correcty these did all clear out within a day but this is also an issue the previous semester faced. If given the option, people will mistype it. I had emails, phone numbers, names, and more all mistyped across forms making it super hard to join against. Expiration logic on an RSVP form is difficult to handle We did have people just fill out the RSVP form without getting their application approved probably had link sent from a friend. I did each wave like every 3 days because our expiration window was 72 hours but this left too many people unsure of their plans if they had to travel up to like 2-3 weeks in advance which isn't ideal. What I would do differently: We didn't at least significantly overadmit in advance to Fall 2023 which was a mistake. We had 300 RSVPs however I think we had an attrition rate to about 230 for RSVP'd guests. Then we had about 30 walkins which we accepted them all up to 263 in total out of 300 guests planned. This worked fine in the sense that we had extra food for everyone and extra swag although we probably should overadmit in advance by maybe 20%? Could run numbers to do this smarter and see where our attrition came from, probably mostly Madison students. I was going to make a little script with a small database for handling RSVP logic that would give some access code to the form for each person, however I decided to make an entire open source event management platform because of it called ApplicantAtlas. As mentioned earlier I should've been more prompt with sending out RSVPs/acceptances, but we were also still trying to get more applicants for MLH which was annoying to deal with. Workshops We also decided that we should run more workshops than compared to the previous semester. Since the previous semester it was just one workshop that I ran on web scraping. What I did: I helped pick topics of the workshops to run: basic html/css/js, intro to react, intro to full stack, and the same web scraping workshop I ran last spring. We ran through all of the workshops about 3-7 days before the event and they were mostly all nicely refined. What I learned: The dry run through is essential to make sure the workshop is up to date and is fresh in someone's mind. We approached it with When I created my workshop I went through an entire ideal target audience for the workshop like what classes they've taken, technologies/languages they're familiar with, etc. I think this was valuable and that all workshops should be required to do this step. We need to have some way for participants to catch up with the code you're typing and some nice way for them to run the code you're running as close to real time as possible. Like someone typing along in a shared google doc, google colab, or putting the solutions up although I don't know if I'd reccomend that. Putting up on the first slide as people walk in the technologies they need and where to find everything to setup the environment was super effective. Personally I like GitHub Codespaces but when I first ran this workshop issues I didn't expect to happen like: random Codespaces issues, browser issues, pip versioning issues, and some people didn't have a GitHub account, things like that which I didn't initially expect. What I would do differently: We need to kick people out of the workshop room before completely because teams stayed in who were just working on project not the workshop and made noise during workshops and such. We probably had too many workshops and not enough social events, I think we just kinda hoped that MLH would save us so we didn't have to do our own fun/social events although that didn't work out as well as we had hoped. Across the board we needed to be better at variations in voice and engaging people more in the workshops itself as many of them felt too lecturey. I think if an organizer's role is to run a workshop it can be risky because the workshop isn't the organizer's main focus usually it's running the event like mine was and I definitely was getting pretty exhausted and mine was one of the earlier workshops. Some of the organizers were up for like 12 hours when running their workshop which isn't great for being engaging and energetic. Photo Booth Ok this is a project that I attempted that did not work well enough to be used at the event but I think it's worth mentioning. What I did: I wanted to make an automatic photo booth that would send emails of the photos out to people who took them. I looked at professional photo booths and they all around us would've been like $1,000 to rent for the event so I thought I could make one for cheaper. I used my Sony a6400 and a raspberry pi to take the photos and send them out. All of the functionality that I wanted did work, although there were some other weird issues specifically with the library that I was using, you can see all the photo booth code if you want. My idea with this project was for more community involvement and getting posts on social media with our sponsors logos in the background without having to wait ~a week for final photos to be filtered and sent out to everyone. What I learned: I used gphoto2 as a python binding, which was the main mistake. I kept running into issues with it segfaulting inside of the C bindings and I couldn't figure out why and I couldn't just use a try and catch because it was segfaulting in the C bindings which is outside of the python interpreter. One annoying thing was that the FPS was too slow initially so what I had to do because microusb only has so much data it can stream through it at once was lower the quality of the preview and the photo to get the FPS up to a reasonable level. Then when taking the photo I would just take a photo at a higher quality and then send that out. I also had a super confusing issue where gphoto2 when taking a photo would be like off by one, and when taking a photo the shutter would move and everything but the photo returned would be the previous photo. What I would do differently: Try to avoid gphoto2 it seemed to be pretty annoying at least with my camera and was the major reason this project didn't work out in time for the event, at least avoid using it as a python binding. Try to use the camera's specific API or features to take a photo with it, unfortunanely there seemes like there's a great sony camera API but it's only for their professional cameras and not their consumer cameras. The Event Itself This segment is about the day of the event. Problems: By far our biggest issue that arose throughout the entire event was that Milio's fucked up our order and delivered our sandwiches randomly put into trays shared together meaning that all food allergens or dietary restrictions were in trays next to sandwiches not of those types. This was a nightmare and we sent out announcements specifying this and I stood at the door asking if people had dietary restrictions or not to everyone who came in to make sure that they knew. I think we did the best that we could but I'm still pissed like months later writing this. Check-in wasn't super fast which was a little bit chaotic like we had our waitlist line which we probably should've said to come later because we just had them in a huge line until checkin for the main event ended Luckily we could admit everyone who waited in the line so it wasn't too bad but it was not great We probably should've had more people helping with check-in, for check-in we had a nice internal tool that would scan QR codes that the previous semester organizers created and let us scan for like meals and such to have data. Our space only really was two big lecture halls and a workshop room which was not ideal because people went to the workshop room to work on their projects and we should've kicked people out of the workshop room before the workshop started (see workshops) Judging was a bit chaotic and the room was crammed, we probably should've put down numbers on the tables for judging before the event started and had a little bit better communication between food and judging as there were a lot of people in the food line before judging started. We had chipolte and we had self service where we were scooping people's food which took too long per person and is something we should not do again. Overall though the event went pretty smooth outside of that and we had a lot of great projects and a lot of great sponsors and mentors. Although I did wish that we had more mentors to help out with the projects as I kept getting asked for help but also had to do a lot of other things at the same time which felt bad leaving someone I was helping to go do something else related to running the event. Our Leadership Structure / Role Distribution This section is about the leadership structure and how we failed to distribute roles and responsibilities in a great way. Context This was the 2nd MadHacks event since after covid and there was a lot of lost knowledge and experience from the previous semester since it was also mainly run by people who were graduating. Most of the organizers were in the UPL which is a self guided student lab/club that is a part of the computer science department at UW-Madison. The way that the mostly club operating lab is structured is super flat and there's not really a leadership structure, so we didn't really have a leadership structure for the event and it heavily relied on people picking up work and doing it. I think this is a good thing for the club but not for the event, I think we should've had a more defined leadership structure for the event. What We Did: We did assign people different roles like catering, judging, finance, workshop leads, swag, etc. And we did have leads for different segments however I ended up doing a lot of work for all of these different segments, partially because I just knew more about the event and what needed to be done and partially because I was the only one who was really doing work for a lot of these segments. People did not really have a great idea of what they were supposed to be doing and didn't have like "success criteria" for their role and it was super broad and not well defined which probably didn't help. However, when we assigned the roles we were operating under the idea of giving people responsibility and letting them figure out what they needed to do and how to do it. I think this is a good idea, however maybe we put too many people on each task and these roles degraded into a "committee" without meetings or anything like that. We did have regular meetings in the summer and during the school year but it felt like nobody was really doing much despite constant reminders and asking for updates on different tasks. What I would do differently: We should have had a more defined leadership structure and more defined roles and responsibilities for the event. So that a few people don't end up doing all of the major work for the event. I don't think this should be like an application process or anything like that but we need more well defined roles for making the event happen. Stagger role responsibilities a little bit better I did a lot of prep work before the event but not much during the event or a week before the event this held true for other people. I think we could've done better making sure people's responsibilities by their role were more spread out like maybe the person handling marketing applications which is really early on in the process could also order swag something like that where they're not doing all their responsibilities at once. We need a better way to communicate what tasks need to be done, who is responsible for what, and when it needs to be done by. Also potentially getting more people outside of the UPL involved in organizing the event before hand or at least with helping with day of logistics Having 12 UPL coordinators is great however after considering for shift rotations for the event we should have more than like ~3-5 organizers there especially as many people needed help for mentorship and such. Conclusion I know this was a long blog post and it might've come across as I was complaining a lot about what went wrong, but I think it's important to document what went wrong and what we could've done better so that we can learn from it in the future. I thought the event went pretty great and tons of people had a great time and made some great projects and that's what's most important and I hope that going forward we can make the event even better and more organized and less stressful for the organizers. Photo Gallery Some photos from the event :D !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 !MadHacks Fall 2023 I wanted to thank the most important people the attendees for making MadHacks Fall 2023 a great event and I hope to see you all at the next one!