Fix common.scheduler.base_weight.BaseWeigher to be Python3 compatible

Use six.with_metaclass to create the metaclass.

Change-Id: I35402d0ce81799fef23849bbb01fa183e145b954