CostWrapper

Wrote a CostWrapper for wrapping cost functions. This will included more
info abt each function, including the weightage and the target layer.
The Layer class should be cleaner to implement with this CostWrapper.

Not tested yet.