I have no clue why people here are comparing a Raspberry Pi with an ESP32, while those products have some tinkering overlap, they are entirely different product categories.
Your Raspberry Pi will have some difficulties running from battery for months while your ESP will already have a hard time driving a reasonably high resolution display for HMI