Here's an old post of mine from 2018, describing my "rules" of pickup placement:
Most of us established (as in grey-haired) Luthiers have gone through the process of messing with pickup positions. When I got into designing and building my own pickups about 15 years ago, like everyone else, I built a bench mule and spent some time experimenting with moving the pickup up and down the body. The results were underwhelming.
Summary:
Take one particular pickup and mount it right in the middle of the body. Set the bass Tone controls wide open, and the amp's EQ controls all on 5. That's the "natural" sound of that pickup, when used with that combination of strings, the bass frame, and the amp.
Now, if you slide the pickup toward the bridge, the change in the sound is all in the bottom end of the EQ. It's just as if you had reached over to the amp and turned the Bass knob down from 5 to 4 to 3. It's not increasing the Treble, it's moderately cutting down the Bass. That's the only thing that's changing in the overall sound of the rig.
Slide the pickup the other way, toward the neck, and you boost the Bass from 5 to 6 to 7. The Treble stays the same; the Bass end of the curve gets louder.
Sliding the pickup doesn't change whether the pickup is muddy or clear, it just subdues it or exaggerates it. If the pickup, by its internal design, is muddy in the bottom end, then sliding it toward the neck will make the muddiness louder and more obvious. Sliding it toward the bridge will make the muddiness quieter. If the pickup's natural sound is very clear and wide range, sliding it toward the neck will boost a clear bottom end. Toward the bridge, it will reduce the bottom end, but still be very clear.
The point is that most of a pickups' tonal characteristic comes from its internal construction; the size and power of the magnetic field, the geometry of the coils, the size and number of turns of wire, etc., etc. None of that changes when you slide it around on the body. All you are doing is moderately adjusting the bottom end of the overall EQ curve.
There are no real "magic sweet spots" in the pickup position. Unless your definition of Magic Sweet Spot is that "the EQ curve sounds just the way I want it right here" or "right here it sounds just like this other bass". Okay. Pickup position is pretty much a linear adjustment. You can slide the pickup where you want it to get the Treble/Bass balance of the EQ where you want it. After you've settled on one position, you can further adjust the EQ balance by reaching over to the amp and turning the Bass knob up or down.
That's what we builders and manufacturers do. We set the pickup position on the body as a final adjustment of the overall EQ balance, for that particular pickup.
A follow-up post:
I notice that no one has yelled
"What about the harmonics?" yet. You know, how pickups have to be placed precisely so you can hear the
harmonics!! The magic sweet spot locations.
Guitar players and builders go wacko about
Harmonics, because they want that screeching dog-whistle high end ringing while they hold a chord, trying to figure out where to go next with the lead.

And some bass players want screeching harmonics too, so they can do solos too.
And by the way, The Screeching Harmonics could be a good band name.
If you want to, you can use measurement and math to locate your pickups precisely at the right spot to
maximize the
screeching harmonics....for a particular set of notes and chords. Up or down a step, and you get gentler normal harmonics.
Personally, I don't build my basses to have exaggerated harmonics on particular notes. I make my pickups to have a nice clear high end, but not excessive extra-highs. And I make them fairly wide aperture, so the harmonics are picked up more evenly on all notes. Less high spikes with position. That's intentional. My basses have nice harmonics, but they are gentle, more in the background, even up and down the scale.
I'm sorry if I've offended the Screeching Harmonics believers.