The Mark 46 and Mark 54 use the same powerplant, which is basically a rocket. (It burns a combination of pipeline glycol dinitrate, 2-nitrodiphenylamine, and dibutyl sebacate.)
Now, you may be wondering how a rocket can burn underwater-it's pretty simple. Fire needs three things: heat, fuel, and oxygen. For most fires, the oxygen in the air is used. However, that's not the only possible source. For example, Otto Fuel II, which the Mark 46 and 54 burn, provides both fuel and oxygen, so the only missing ingredient is heat. Once heat is added, you get a very powerful (4 horsepower per pound) rocket engine that works in air or underwater.
Super-cavitating torpedoes, like the Russian VA-111 Shkval are also rocket-powered. They move at extremely high speeds which essentially causes water to vaporize. (We generally think of boiling as being something caused by a change in heat, but that's not necessarily the case. Fluids boil in response to changes in heat or pressure; on your stove, the boil is caused by heat. But underwater it's caused by pressure.) The cavitation doesn't actually propel the torpedo, it just makes it more slippery.
The term "wet-heater" refers to a kind of combustion torpedo. The torpedo would be burning something like kerosene, which generates a fair bit of heat that's essentially wasted. So water was used to cool the combustion chamber which, in turn, generated a lot of steam. This steam was then used to create additional pressure that augmented the power already created by the combustion engine. (Note that this isn't a combustion engine in the same sense as the engine in your car. This is still basically a rocket engine, except the combustion occurs in an internal combustion chamber as opposed to externally.)