First row: number of pieces with 3 squares or more = 5; number of squares missing = 8. 5x10+8=58.
Apply the same formular to the second row: 4x10+12=52.
I am sure there are other possibilities. E.g., the second row could also mean 412. If either of my answers is the one you have in mind, then I must be a good mind-reader.
I count the squres in the first row and try to correlate the number with 58 and then do the same thing for the second row.But not sure whether it is correct