You don't need to know if people live there, just raise tax enough so that the owner feels like renting or selling the building is better than paying the taxes out of pocket.
This also forcess poorer people (including retired people) to sell off the house they are actually living in. This is especially true if the tax is based on the current estimated value which may be much higher than what the house was bought for.
There are ways around this. For example set a property tax from second home on. Do not tax the primary residence. Or set income brackets. If poorer people live in their own homes they don't pay property tax.