I wrote some simple open source web-based app to (1) dynamically compute knitting patterns (based on input parameters, such as the exact desired size), and (2) display these patterns and help me keep track of which row I'm on (as I start knitting), similar to minimalist "row counters" that other knitters use. It also gives you a simple visualization of the shape of what you're knitting. You can see it in action at <a href="https://alefore.github.io/knit/" rel="nofollow">https://alefore.github.io/knit/</a> (and read about it in <a href="https://github.com/alefore/knit">https://github.com/alefore/knit</a>).<p>Right now I only implemented on simple pattern: Sophie scarfs. After knitting one that came out somewhat … asymmetric, I decided to just write some software to help me (1) easily adjust the length/width of the scarf (using Bézier curves), and (2) keep track of which row I'm on (so that I can make sure I apply increases/decreases at the right places). In the future, I expect to extend this with many other knitting patterns for other types of items.<p>The application is 100% browser (JavaScript, tested in only in Chrome in Linux/Android) based (no server-side component): all state is kept in the URL hash. I've used it to knit two scarves, including <a href="https://github.com/alefore/knit/blob/main/images/000.jpg">https://github.com/alefore/knit/blob/main/images/000.jpg</a>.<p>The current state of knitting patterns is far from optional, stuck in pre-computer times. Perhaps knitters are not the most technically minded group. Most knitters just download patterns as PDF files. These files will show multiple numbers from which you should choose one depending on the size you're knitting, saying things like "Purl 24 (32 38 42 50 64) times" (you're supposed to pick the right number depending on the size you're knitting). They'll say things like "repeat rows 4 to 6 sixteen times".<p>I think software can display patterns much better (including not being limited to a few pre-selected sizes, but letting you choose the _exact_ size you want, and adjusting everything accordingly), and keep track of your progress much more easily. For example, for my scarf, the user inputs the desired number of rows (based on the desired length, which makes the pattern agnostic to the needle size), and the software computes where to apply increases/decreases.<p>I have many other ideas for improvements (e.g., track how much time I've spent in each row, show a clock), but I figured I'd share this early and ask for feedback. Hopefully there are other fellow knitters in HN. :-) Check it out and let me know what you think!
I started learning to knit last fall and I have been really enjoying it.<p>If you're a software engineer, I think it scratches a lot of itches:<p>1. Knitting patterns are sort of like a tiny little programming language, with loops (as in iteration, not as in, uh, loops of yarn) and choice.<p>2. Knitting charts are a lot like pixel art.<p>3. There is a very fine-grained skill progression where you can ease your way in by starting with simple patterns that only use a few techniques. But there is always a next level of skill and challenge. The lore is incredibly deep and there is a <i>ton</i> to learn. You'll never run out of ways to improve your expertise. At the same time, even as a beginner, you can make objects that are useful and beautiful.<p>4. If you're tired of staring at a screen and crave something tactile, it is an excellent counter-point. It's extremely tactile, hands-on, and texture-oriented. It just <i>feels good</i> to knit or play with yarn and textiles. There are so many rich colors and color combinations at a level of vibrance that a screen never attains.<p>5. If you're mentally tired at the end of the day but still want to feel like you're making progress on something meaningful instead of just scrolling on your phone, you can always pick up a project and knit a few more rows without needing a lot of brainpower. At the same time, you can also choose projects with enough complexity that it doesn't feel totally mindless like a coloring book or something.<p>6. Unlike software where much of our output is intangible and meaningless to the world, <i>everyone</i> can see and appreciate knitted objects. The things you make are instantly beloved and appreciated.<p>7. If you are introverted and prone to anxiety, knitting is a very nice therepeutic escape.<p>I highly recommend it.
This is great! I'm also a knitter, and I really like putting together little programs to help me design or write out patterns. My favourite so far has been an Elixir Livebook notebook I made to design a scarf for my partner. It outputs row counts and an image of what the end result will look like: <a href="https://put.bo0tzz.me/s/30iu0n2k.png" rel="nofollow">https://put.bo0tzz.me/s/30iu0n2k.png</a>
The (messy) livebook code is here for whoever is interested: <a href="https://gist.github.com/bo0tzz/eb7818f7db3542ec540965252a3442d9" rel="nofollow">https://gist.github.com/bo0tzz/eb7818f7db3542ec540965252a344...</a><p>Another program I made (and unfortunately lost) was one to generate bespoke sock sizings (and corresponding pattern instructions) from measurements I put in.
Nice idea. I love how you manage to show the shapes of the design. But how do you know the size of the finished object? I assume you ask knitters to do the calculations themselves. That can be difficult (for me it was until I put words on it).<p>Being a long time knitter and also a designer (not a professional designer, but just someone that likes to design her own patterns and doesn't like to follow other patterns), I did several knitting tools using LibreOffice Calc (may be you can call that "old school"), you can download them here: <a href="https://www.aiguilles-magiques.com/-Outilsde-creation-?lang=fr" rel="nofollow">https://www.aiguilles-magiques.com/-Outilsde-creation-?lang=...</a> Sorry but they are mainly in French. Well, the sweater calculator is in English too.<p>For these tools, I just ask the knitter to enter the gauge and, yes, all the necessary measurements. The sheets make all the maths. Obviously there are way perfectible, and they don't show the shape of the finished as you did for your tool (notice the picture on y tools were made with Inkscape).<p>All this tools are under licence CC by-sa.
As a fellow knitter, this is pretty neat--I really like the notation. I mostly make hats, and do most of my pattern work using a pixel art app and a piece of paper for notation.<p>Any interest in expanding the scope of this to include other designs? Double knitting? PRs welcome?
While your point about knitting patterns being largely unchanged by computers is true, there are a few very good software-enabled knitting tools out there:<p>- KnitCompanion is a complex but extremely powerful app to take PDF patterns and turn them into very efficient, effective digital patterns. You can designate specific steps, walk through steps and charts with voice control, extensively reformat a pattern, etc. I use this for all moderately complex knitting.<p>- TinCanKnits is a pair of pattern designers who have recently released an app for their own patterns that customizes the pattern (showing only your size, changing chart colors to match your yarn, etc.)<p>- CustomFit by Amy Herzog is a tool with a collection of sweater designs that can be fully customized to your own gauge, measurements, design preferences, etc.<p>- There are a number of calculators out there for sock knitting (how many stitches/rows for heel flap, gusset calculations, etc.).
A while ago I started to build something similar, but I didn't get much farther than choosing a name for the project (<a href="https://github.com/mk12/loopy">https://github.com/mk12/loopy</a>). I want to design a language that can specify patterns precisely and unambiguously, and then visualize them in a physically accurate way. For basic 2D patterns I was thinking I could render each stitch based on it and its neighbors (3x3 grid of K/P). But that wouldn't be that useful. What would really be neat is to use a physics engine to simulate the yarn in 3D. For example the simulations would show stockinette curling and ribbing stretching without that being hardcoded anywhere. But I think it's too hard and I have no idea where to start with that.
This looks intriguing! One thing I'd like to ask is to increase the button and overall font size since it looks a little bit tiny on mobile, which might be the platform people use when they don't knit in front of their monitors.
> <i>"Purl 24 (32 38 42 50 64) times"</i><p>Syntax like this is probably why wartime censors disapproved of mailing knitting patterns.<p>EDIT: someone needs to write a short story procedural in which the plaintext turns out to be a knitting pattern.
Nice! Friend of mine loves knitting!<p>But in the example in your Github, was does "2K KFB 6K WYIF 3SLP" mean?
The explanation is "The rest are the steps for this row.". I don't understand.
Can somebody explain?