How do we know how many layers are there to use

Why does the first hidden layers has 25 units and the second has 15 units?
image

Just an arbitrary choice.