Officer Shaw and Officer Neal are clearly Petty Officers from the insignia on their uniforms. Therefore their title is 'Petty Officer' or 'PO' - not 'Officer'.
The Commanding Officer of the Gartside is a substantive Captain, his uniform indicates. A Captain would not be in command of an Upholder-class diesel electric submarine in the Royal Navy. That would be a Lieutenant-Commander or, at the most, a Commander.
The Royal Marines are part of the Royal Navy, not part of the Army, as Matt states.
The cap badge of the submarine commander is not a Royal Navy cap badge.
Some members of the crew call the submarine a ship. Submariners call their vessels boats.