I often raid harbours, and in the very shallow littoral waters it is often a good idea to expend a torpedo on a target such as an ASW Trawler or a patrolling destroyer lest they detect you on the infiltration/exfiltration stages of the operation. Inside the harbour itself, assuming you can bypass any minefields and/or anti-torpedo/anti-submarine netting, you're usually fairly safe, they can't get inside after you and will sometimes collide with breakwaters and scupper themselves.
However, it's never a good idea to use an ato (gas-steam torpedo) on a military target, their watchkeepers are typically pretty good and they often have the agility to get out of its path. It doesn't take much to screw up the solution if they spot it early enough. When attacking convoys, I'm usually sorely tempted to shoot the escorts, as then I can reload at my leisure and attack the convoy repeatedly. Convoy escorts however tend to be more dynamic than patrols in littoral waters and are difficult targets; hence the concept of engaging the merchantmen and diving away from the escorts.
Military vessels (and not just the big gun battleships or an aircraft carrier) seem to carry a lot of renown value. I've noticed a pretty significant difference in my 'merchants only' renown values versus 'everything that floats' renown values after certain patrols.
Best weapon/tactic combination for an attacking destroyer, in my experience, is to center my bow on the middle of the arc he travels through as he zig-zags towards you, set a gas-steam torpedo to run fast, and when he's within 700 metres I fire at him just as he begins a fresh zig or a fresh zag. The torpedo should be able to hit him before he can alter course. Torpedoes seem to need at least a 250m run-distance before their safeties disarm. Anything closer than 250m attacking you, you won't have time to set a solution up and engage unless you're very good, in which case you already know the required distance for your torps to arm themselves.