Wednesday, February 8, 2023

If I Made a List of Knitting Stitches

 If I made a list of knitting stitches, what information would belong in that list?  What information would belong in separate, related lists?

Analyzing the attributes of data, in this case attributes of a knitting stitch pattern, is referred to as normalizing the data.  The attributes get sorted into tables.  The ideal condition is to remove redundancy in the tables by putting the attributes that have redundant values in separate tables.  In most cases a condition known as 3rd normal form is the sweet spot of normalization.  There are higher levels of normalization.  Those higher levels are the concern of mathematicians with autistic savant tendencies.   Even when trying to apply 3rd normal form it is not uncommon to cheat a bit.  

A knitting stitch has a name.  Some knitting stitches have more than one name.  Does the knitting stitch have a name or does the name have a knitting stitch? 

For the purpose of making a database table (list) of knitting stitches and the attributes of the knitting stitch, it works out better to treat the name as if it has a knitting stitch.  Because this can create a wrinkle when, later, associating other features of a knitting stitch pattern, the knitting stitch name is not the best way to define the relationship between a knitting stitch name and, for example, the rows that are included in the instructions for the knitting stitch.  To manage the wrinkle an artificial key field is included.  The artificial key is a Stitch ID or record number.  The database management system has tools that automatically create the next record number.  That automation relieves the person entering data from keeping track of what the last number was.


Stitch ID Stitch Name
1 One x One Ribbing
2 Knit One Purl One Ribbing
3 Trinity 1
4 Trinity 2
5 Bramble

In this example Stitch IDs 1 and 2 describe two names that refer to the same knitting stitch pattern.  
Trinity 1 and Bramble are also two names for the same knitting stitch pattern.

Remember what was said above about cheating a bit?  Trinity is also the name given for more than one unique knitting stitch pattern.  Rather than trying to normalize to a higher level, this example uses a numeral following the name to give each unique stitch patterns a unique version of the name.

Another set of attributes for a stitch pattern describes the number of stitches and rows that make up the stitch pattern.  Stitches and rows have a number of stitches and rows that are repeated when working the pattern.  There may also be some 'plus' stitches or rows.  The 'plus' stitches and 'plus' rows are not repeated.  The plus stitches help to maintain a symmetry on the edges of a knitted fabric.  Plus stitches are often found on lace and cable patterns.  Plus rows are sometimes used to create a 'foundation' for a pattern.  Often there are no plus stitches or rows.   


Stitch ID Stitch Name Stitches StitchesPlus Rows RowsPlus
1 One x One Ribbing 2 0 1 0
2 Knit One Purl One Ribbing 2 0 1 0
3 Trinity 1 4 0 4 0
4 Trinity 2 4 1 4 0
5 Bramble 4 0 4 0

At this time the stitch name table in Knittingfool.com has the following structure:  

[RecNum] [int] IDENTITY(1,1) 
[StitchName] [nvarchar](255)
[Stitches] [varchar](35)
[StCount] [smallint]
[StitchesPlus] [smallint]
[Rows] [smallint]
[RowsPlus] [smallint]
[Category] [nvarchar](50)
[attribution] [varchar](255)
[URLCode] [int]
[picture] [varchar](200)
[h1] [int]
[w1] [int]
[memberflag] [int]
[picture2] [varchar](200)
[attribution2] [varchar](100)
[attribution3] [varchar](100)
[symbolstatus] [smallint]
[graphic] [varchar](200)
[thumbnail] [varchar](200)
[ChangeDate] [datetime]

Some of these fields, such as URL Code and membership flag, are artifacts from earlier development experiments that are no longer used.  They should be removed but there is always extra caution surrounding removal of fields, so it doesn't get done until there is a major rewrite.

Stitches and StCount are redundant.  There was a reason to have both.  Note that one is a varchar (i.e., a text or a string value) and the other is a small int (i.e., a number value.  I would have to research where these values are used in the code to refresh my memory about these two fields.

Some fields are not normalized very well.  For example, picture and picture2 should be in a separate table.  The same is true regarding the attribution fields.  There are a lot of things I would do differently if I did the whole thing over again.  Most programmers cringe a little when they review code they wrote years ago.  

Saturday, January 21, 2023

Would You Like A Website?

I'm looking for someone with the right skills to take over the Knittingfool.com website.  I'm not looking to sell it.  I'm getting older and I want to find an heir for the site.

Let's deal with some likely questions.

Financial considerations:  Originally, I used a membership model to try to monetize the site.  I charged $10 for an annual membership.  I plateaued with about a hundred members.  Not much money there.  More important to me, my efforts were only seen by a small number of people.  I evolved it into a free site and brought in Google ads.

Up until December of 2014, the site pulled in $300-$400 a month from Google ads.  Then as if a switch had been flipped, beginning in January 2015, the revenues fell precipitously to the point where I was lucky to make $50 a month.  What happened?  The traffic on my site had not changed. I will probably never know.  Did the social justice warriors at Google find out that I'm Pro-Life?  Did they learn about my Lifetime NRA membership?  Who knows?  

Eventually I removed the Google ads because they did not pay enough to support tolerating their annoyance.  I settled for a donation model.  The site's net result is an annual loss of $200-$300.  Could someone else do better?  Yes.  I treat it like a hobby, and I get hobby results.  It probably could be monetized better.  It might have to be rebranded with a new domain name in case Google has settled a curse on knittingfool.com.  

I don't know what my site traffic is today.  After I took off the Google ads, I lost interest in the traffic level.  

Skill set considerations:  The site uses a SQL Server database.  The pages are written in ASP.net.  I use forms created in Microsoft Access to manage data entry into the SQL Server database.  I learned my technical skills in the gutter.  As a result, my programming is sloppy, however, it is not very complex.  The method I used to put charted patterns on the screen is the only part that gets difficult.  I have an image for each cell in the chart.  The images are numbered.  Instructions in the database manage the placement of the images into rows and columns on the screen.  My method for displaying charts could be easily replaced with a simple, whole chart image.  

Before anyone could take over the website, I must write documentation to explain the database tables and the web pages.

I may use this blog as a place to hold the documentation.

Let me know if you are interested.  Or if you have questions.


Saturday, September 4, 2021

Sea Cucumber

 I just stuffed some yarn puke back into the center of a gradient cake.  Suddenly the image of stuffing guts back into a sea cucumber popped into my mind.  It could have been worse.  I could have thought about a Dr. Pol episode.

Thursday, January 28, 2021

16,222 Projects; 16,191 WIPs

When I go to Ravelry, like most, it is usually to scout out some free patterns.  I don't explore outside the Pattern tab very much.  Today was an exception.  I noticed Friends on the drop down menu.  No surprise, I don't have any friends.  If I had a friend on Ravelry, that person might be tempted to report me to be kicked off Ravelry.  My world view is probably not the sort that the Ravelry admins would like.  

On the line menu at the top of the Friends page there was Neighbors.  What could that be?  Geographical neighbors?  It turns out that my Ravelry neighbors are people who have posted projects using the same patterns I used in my posted projects.  

My first 'neighbor' had four project patterns in common with me.  However, the shocking part was that this person has 16,222 projects, of which only 31 had been completed.  That leaves 16,191 Works in Progress.  Let that sink in.  

I feel guilty if I have six WIPs.  Each WIP is in a separate project bag and I've only got so many project bags.  If my 'neighbor' had 16,191 project bags, maybe someone on Etsy might be getting rich. 

I'm hoping most of the 16,191 WIPs are items that would more properly belong in the Queue menu item.  That's where all my aspirational patterns are listed.  I currently have two items in my queue.  Even having 16,191 items in a queue would seem to display a lack of sorting and prioritization.  

Maybe Discovery will come up with a show called My 16K WIPs Life.  Sounds kind of kinky when it's put that way.

 

Sunday, April 26, 2020

Living on Covid Time

Last year I made a Shiri wrap and gave it to my daughter for Christmas.  I noticed my mother-in-law having an eye for it and she kept running her hands over it.  So I made another one, almost identical that I plan to give her for Mother's Day.  I got it off the needles Friday.  It took 4 Covid weeks (that means working on it about 10 hours a day because what else have I got to do) to make it.


I blocked it on the kitchen table Saturday.  We had to eat our meals at the kitchen counter for a little while.


I took these pictures this morning.


It is 70% alpaca, 20% silk and 10% cashmere.  Too bad you can't touch it because it is a wonderful experience.  


For those who want the particulars, the pattern can be found at Ravelry.com.  It is called Shiri by Ambah O'Bien.  The yarn is Winter Light Lace from LuckyVioletColorCo.com.  

The yarn was a Christmas present from my son in 2018. When he asked me what I wanted for Christmas I gave him the URL for a page on the Lucky Violet Color Co. web site. The only instruction I gave him was 'no pink.' I did not tell him what yarn base to select.

The Lucky Violet Color Co. has a lot of yarn bases and they dye the yarn to order. My son apparently studied this situation and decided that the best option was to get the most yardage per skein. I think this reasoning process may be an anecdotal example of the difference between the way a non-knitter (especially a guy non-knitter) and a knitter look at this sort of thing. So he picks the Winter Light Lace that is nearly cobweb weight (1300 yards per 100 gram skein). And gets me six skeins, two each of three different blue shades.
I wasn't quite sure what I was going to do with this very light weight yarn. I was a little intimidated. What was I going to do with 4-1/2 miles of light lace weight yarn? I do a lot with fingering weight yarn but I don't venture into the lace weight very often at all. On the bright side, the fiber in this yarn is wonderfully light and soft; he made a great choice in that respect. When I found the Shiri wrap pattern I saw a way out of the predicament. I was able to use two strands together to achieve an ordinary lace weight.
The pattern is not too difficult; a little simple lace alternating with bands of garter stitch. The construction calls for making two identical large triangles.  Then the triangles are joined together with a three-needle bind-off. The only challenge is the I-cord border around the whole thing; not because the I-cord is difficult, but because it is a l-o-n-g way around the wrap, like about 1200 stitches.  The I-cord method requires working three stitches to bind off one stitch so 3600 stitches to finish the cord edging.
The only problem is that I still have enough yarn to make another one, even after the one I made earlier for my daughter. If I ever send my son to a yarn web site, I'll do a better job with the instructions. 

Tuesday, April 14, 2020

Pandemic Memories

The Covid-19 virus (aka Wuhan virus; aka Chinese virus; aka Corona virus; aka CCP virus) pandemic is my fourth pandemic.

1.  Asian flu pandemic 1957.  Well, I was a toddler so I don't recall so much.  Apparently that year measles were a greater threat to me.  Measles hospitalized me; I was packed in ice to reduce my temperature.

2.  Hong Kong flu pandemic 1967-1968.  I remember this one well; I was a teenager.  We were on vacation at Carlsbad Caverns.  In a crowded cafeteria we shared a table with a woman from the West Coast who was sniffling and snuffling.  After we got home we all came down with the flu.  It was bad.  My Dad took it the worst.  He was a three-pack-a-day smoker and he ended up in the hospital with double pneumonia.  It damn near killed him.  No ventilators then, just an oxygen tent.   In the USA 100,000 death were attributed to the Hong Kong flu.   There were a million deaths world wide.  If they quarantined anyone I never heard of it.  Businesses did not close.  Life went on.  I don't remember any crisis mentality. 

3.  Swine flu pandemic 2009-2010.  I don't recall this Swine flu pandemic nearly as well as I remember the 1976 Swine flu outbreak.  I think the press kept the reporting low-key. 

4.  CCP virus pandemic.  Of all the many names for the current pandemic I like CCP pandemic best of all:  Chinese Communist Party pandemic.  I found that names in the Epoch Times.  Because I am retired my life in the 'lock down' is not much different than before.  Just glad I live in a rural area where I can go outside and walk around all I want.  The biggest differential I have noticed between this pandemic and the earlier pandemics is the damn, awful 24/7 news coverage.  So much jabbering from people who have a lot of opinions and not enough facts or good sense.  Unfortunately my husband insists on watching one of the business news channels all day long.  I expect people discussing business to be rational.  Instead there is way too much hair-on-fire disinformation. 

Since everyone else is jabbering, here's my bit:  I think the lock down has reached the point where the Law of Unintended Consequences is taking over.  Those Consequences will soon be more harmful than anything the lock down is intended to prevent.  The effects on mental health and the economy are becoming a greater risk to our well being than the virus.

Friday, March 27, 2020

Google User Interfaces Now In Human Trials

A little over a week ago my laptop computer experienced a disk crash.  After a prolonged scan and repair, most of my apps and data were still available.  The Start feature did not work and the Search feature in the Task Bar did not work.  A couple icons on the Task Bar did not work, returning a "Class not registered" error message.

I ordered a new laptop.  While I waited for the new one to arrive, I got along with some work-arounds.  Ctrl-Alt-Del got a workout.  To open applications I had to use Task Manager\File\Run New Task.  That works well if you can remember the application name that the System expects.  There was one application, a scanner manager, that I never did figure out, even after a long search of the registry. 

Wednesday the new laptop arrived.  I was pretty good to myself:  1Tb Solid State Drive and 1Tb conventional hard drive.  Plenty of memory.  The graphics card is not the very best, maybe in the tier just below because I don't want the kids coveting this laptop for gaming.

I made a mistake during the set up which resulted in my C:\Users account name being different than what it had been on the old machine.  Fixing that in the registry took a lot of time because that file path appears in many registry entries.  I wish I could have found an easier way to change that.  I can't be the first person to have that problem.

I have spent two days migrating into the new machine.  I used an external hard drive to move files.  I audited the files to ensure the same number of files were on both the old and new machines and in all the same places.  Setting up email was not too difficult.  I checked and double checked all my connection settings.

Most everything went well until this afternoon when I tried to get into my Google Adsense account.  The Google Login security raked me over the coals.  Being on a new machine probably raised some flags.  It doesn't help that I have two Google accounts; that part of the problem is my fault.  I ended up in a loop that started with Google Security wanting to verify my account by re-entering my password.  I submitted  the password; it gave no indication that there was a problem with the password.  It looped me back to the screen where Google Security wanted to verify my account again.  And the loop just kept repeating.  So I selected the "Forgot Password" option to try to get out of this loop.  After I changed the password, it put me through the same verification loop as before. 

I futzed around with Google Security for over an hour.  If Google Security ever steers you toward an option to use your phone with a screen lock to sign into your account, please, please please don't do it.  It just put me into a similar loop and when I found the setting to turn that feature off, Google had warning messages designed to add fear to my loathing.  I was so frustrated with all the rigmarole Google was marching me through.  Has the testing of Google's Security user interfaces reached the level of human trials?  Was I in the human trials?  Was someone at Google getting paid to torture me, take notes and laughing about it?  I was in such an internal storm that I don't even know what I did to finally get into Adsense. 

This was not my first Google goat rodeo; probably won't be my last.  I need some wine.