Please attach the entire file. Because it doesn't seem to be the real code that is going wrong, since there is no sYieldName = 'ftb.Tech.TimedTorpedoes' line in the supplied code snippit.
Also, this is by your own doing (as in, you tried to script) so I'm moving this to Scripting.
But I see a problem already (maybe not the problem), Python is sensitive to "indentation".
And you need to keep it consistent, otherwise it won't know where you are.
I assumed you wanted the torpedo to split with the parameters you suplied, also, it's advisable to replace things like "Name for tech" with your own name + the type of tech.
In this case, I renamed it (for you) to 'FekLeyrTorpedoSpread3'. This will ensure it's unique.
Here is the (mostly) fixed part:
sYieldName = ??
try:
import FoundationTech
import ftb.Tech.TimedTorpedoes
oFire = ftb.Tech.TimedTorpedoes.MIRVSingleTargetTorpedo(?FekLeyrTorpedoSpread3?, {
?spreadNumber?: 3,
?spreadDensity?: 6.5,
?warheadModule?: ?Tactical.Projectiles.PhotonTorpedosplit?,
?shellLive?: 0,
})
FoundationTech.dOnFires[__name__] = oFire
oYield = FoundationTech.oTechs[sYieldName]
FoundationTech.dYields[__name__] = oYield
except:
pass
[EDIT]
*Moving*
Also, some of the indentation is "artificial" and added by myself to improve clarity. The indentation is only important on each new code line. A code line (what Python sees) is diffrent than a text line (what you see).