Software/Programme for counting objects in a photo

Hi everyone, I am running a timelapse camera which takes one photo every 10 minutes of a harbour landscape. I'll be running the camera for months to years and I'm looking for a method of analysing the photos quickly. What I want to know is-how many boats are in each photo? I expect that any solutions wont be entirely accurate and that I would need to do a control manual analysis of some of the photos, to get a measure of the accuracy/reliability. Is there a method for doing so in R or Matlab, or do you know any existing programmes that have such recognition features, maybe there is a software you can train to recognise boats once you do enough manual photos yourself? If you have any suggestions or pointers, it would be great to hear from you! Thanks