You could check the image orientation in Windows by right clicking an image file, select Properties, and open the Details tab. Not sure if you're using a Mac but I would suspect there will be something similar.
The Dimensions property will show the horizontal side (on the left) and the vertical side (on the right). So, if the horizontal size is the biggest size, then the orientation must be landscape. If the vertical size is the biggest, then the orientation must be portrait.
I checked this with two CR2 RAW files from a Canon mirrorless camera that records the orientation when shooting, for both a landscape and portrait photograph. I didn't rotate either of these images manually. The OS picked up which way to rotate when I transferred the RAW images to my computer.
Obviously I also have a codec installed for Windows that displays the CR2 Thumbnails in Explorer (can't remember which one I installed), so I can see the orientation anyway. Perhaps that is one route you could go down.