Refactor OS stats
Merge pull request #3446 from openscholar/os_stats_refactor

Refactor OS stats