Got top categories section in user profile to work. Updated callbacks in project.rb and project_interest.rb and ran sort.by on hash in user show page to correctly display # of projects for the user's categories in descending order.