The problem is probably related to one of two items.
1. Injector nozzle not spraying a mist (clogged injector)
2. High pressure fuel pump output sending wrong amount of fuel to cylinder.
#1 can be fixed by removing the injector and taking it to a diesel shop so they can pop test, and if required replace the nozzle. They can shim the injector to meter the right amount of fuel. Pull them both and label which cylinder they are matched to. When replacing the injector, be sure to replace the mica insulator that fits between the injector and the head.
If that doesn't fix it, next try
#2 requires returning the high pressure pump to a Yanmar repair facility. They can rebuild the seals and setup the fuel rack for proper metering of fuel at all rpms. This requires special test equipment and is why the task needs to be done at the Yanmar repair center.
Refer to section 3 of the
2QM15 Service Manual located on the J/30 page under the menu
Info,
Diesel Engine Maintenance. This has detailed diagrams and rebuild procedures for the injector and fuel pump.