core: fixed log density issue.