You may want to try the VMAF metric to find a best setting for you content.
https://forum.doom9.org/showthread.php?t=175862
First you start with an base encode like crf 23 medium. Then use the plugin to compare that encode to the source, it will then gives you a perceived visual score.
Then you repeat this process with a different setting until you satisfied.