The yellow number at each corner counts the number of squares with that location as its lower left corner.
The red "1" is perhaps not a square. I had erroneously counted it, thinking that the other crossing lines were 1/6 of the big square. But they seem a bit larger.
This is only counting squares whose edges are completely present. For example, I am not counting the green square drawn in. If we can count this kind of square, I think there are even more squares, but it's too hard to know what the rules for stopping might be.
@francoise Thanks Francoise, I will include a link on my project. I don't think there are any rules apart from counting squares. I found this activity on a Brain Teasers website, so that's what they are meant to do - great for getting my maths club kids to think outside of the box...