yes you can swap 2.5 sohc heads on a 2.5dohc block. make sure you use the Dual headgasket, as there thicker. The dohc pistons come past the deck a bit and need the extra clearence inthe gasket. Thats the main thing! your intake from your sohc 2.5 will fit on the dual block with sohc heads.
Only other thing is there is a lil bracket above the water pump that differs from dohc to
sohc. Other than that, Its a very simple swap.
Pull the heads off that Dohc and when you have just the block, check for knocks the best you can. Listen+ Feel, every piston at/and before tdc. and also at/and before Bdc