Use a wide blade drywall taping tool against the cabinet base and walls. That will stop you from cutting into the cabinets and wall. You will be able to cut the carpet at a slight inward angle. Use a carpet knife to cut the carpet. Not the hooked one

You should be able to push the remaining edge under the cabinets.