Yes indeed.
For the metrics, you need to write your functions that delegates the mask part to the function you want.