It hurts you, it is like buying something you know you can't afford.
It might hurt you less than doing something else but it still hurts you.
It is maybe not immediately evident how it hurts you but neither is living beyond your means immediately painful.
It is like stealing from yourself because you are with that conditioning your brain in a wrong way and it is you who will have to put in the work to undo it in order to direct the mind to the Eightfold Path.
Furthermore when you understand your behavior to not be in line with your ideals you will experience a lot of anxiety and vexation.
This can not be avoided because your brain is then wired in a way that you know that you are essentially breaking yourself when you do what you know you shouldn't do and aren't doing what you think you should be doing.
When you have work to do for the undoing of unwholesome tendencies which are a result of a frequent giving of unskillful attention, then you are just adding insult to injury by signing up for more sadness that doesn't have to be there by doing more of what got you into trouble in the first place.
Does this make it a sin?
I don't know this term's application here but it's certainly on a spectrum of bad behavior, even tho the thoughts of restraint & avoiding women are more or less skillful.
That being said restraint is good in all circumstance and if feel this makes things easier for you then it's obviously the lesser evil and you should pick that over having intercourse until you can undo & overcome.
Id say don't worry about it but also don't fool yourself into thinking that there is no harm in that for you because it certainly is a stumbling block and you should recognize danger in trifling things because it's likened to grasping a hot rock, it is better to know that ut's hot to minimize the damage.
Here pali sutta instruction
Bhikkhus, to the bhikkhu practicing the perception of loathing and
abiding much in it, the sexual thought keeps away, it shrinks and
[a] “And what, Ānanda, is the perception of unattractiveness? Here, a
bhikkhu reviews this very body upward from the soles of the feet and
downward from the tips of the hairs, enclosed in skin, as full of many
kinds of impurities: ‘There are in this body hair of the head, hair of
the body, nails, teeth, skin, flesh, sinews, bones, bone marrow,
kidneys, heart, liver, pleura, spleen, lungs, intestines, mesentery,
stomach, excrement, bile, phlegm, pus, blood, sweat, fat, tears,
grease, saliva, snot, fluid of the joints, urine.’ Thus he dwells
contemplating unattractiveness in this body. This is called the
perception of unattractiveness.
[x] "Furthermore... just as if a sack with openings at both ends were
full of various kinds of grain — wheat, rice, mung beans, kidney
beans, sesame seeds, husked rice — and a man with good eyesight,
pouring it out, were to reflect, 'This is wheat. This is rice. These
are mung beans. These are kidney beans. These are sesame seeds. This
is husked rice,' in the same way, monks, a monk reflects on this very
body from the soles of the feet on up, from the crown of the head on
down, surrounded by skin and full of various kinds of unclean things:
'In this body there are head hairs, body hairs, nails, teeth, skin,
flesh, tendons, bones, bone marrow, kidneys, heart, liver, pleura,
spleen, lungs, large intestines, small intestines, gorge, feces, bile,
phlegm, pus, blood, sweat, fat, tears, skin-oil, saliva, mucus, fluid
in the joints, urine.' "In this way he remains focused internally on
the body in & of itself, or focused externally... unsustained by
anything in the world. This is how a monk remains focused on the body
in & of itself.
[y] "Furthermore... just as a skilled butcher or his apprentice,
having killed a cow, would sit at a crossroads cutting it up into
pieces, the monk contemplates this very body — however it stands,
however it is disposed — in terms of properties: 'In this body there
is the earth property, the liquid property, the fire property, & the
wind property.' "In this way he remains focused internally on the body
in & of itself, or focused externally... unsustained by anything in
the world. This is how a monk remains focused on the body in & of
 "Furthermore, as if he were to see a corpse cast away in a charnel
ground — one day, two days, three days dead — bloated, livid, &
festering, he applies it to this very body, 'This body, too: Such is
its nature, such is its future, such its unavoidable fate'...
"Or again, as if he were to see a corpse cast away in a charnel
ground, picked at by crows, vultures, & hawks, by dogs, hyenas, &
various other creatures... a skeleton smeared with flesh & blood,
connected with tendons... a fleshless skeleton smeared with blood,
connected with tendons... a skeleton without flesh or blood, connected
with tendons... bones detached from their tendons, scattered in all
directions — here a hand bone, there a foot bone, here a shin bone,
there a thigh bone, here a hip bone, there a back bone, here a rib,
there a breast bone, here a shoulder bone, there a neck bone, here a
jaw bone, there a tooth, here a skull... the bones whitened, somewhat
like the color of shells... piled up, more than a year old...
decomposed into a powder: He applies it to this very body, 'This body,
too: Such is its nature, such is its future, such its unavoidable
Or developing this line of reasoning acc to comy if u want to try;
“When this body is born it is not born inside a blue, red or white
lotus or water-lily, etc., or inside a store of jewels or pearls,
etc.; on the contrary, like a worm in rotting flesh, in a rotting
corpse, in rotting dough, in a drain, in a cesspool, etc., it is born
in between the receptacle for undigested food and the receptacle for
digested food, behind the belly lining, in front of the backbone,
surrounded by the bowel and the entrails, in a place that is stinking,
disgusting, repulsive, and extremely cramped, being itself stinking,
disgusting, and repulsive. When it is born thus, its causes
(root-causes) are the four things, namely, ignorance, craving,
clinging, and kamma,  since it is they that bring about its
birth; and nutriment is its condition, since it is that that
consolidates it. So five things constitute its cause and condition.
And of these, the three beginning with ignorance are the
decisive-support for this body, as the mother is for her infant, and
kamma begets it, as the father does the child; and nutriment sustains
it, as the wet-nurse does the infant.”