Deep Coral Loss for semantic segmentation

I have two image’ features outputted from the semantic segmentation feature extractor with the following sizes:
image1 feature = [ 8,2048,16,16]
image2 feature = [ 8,2048,16,16]

i want to compute the Deep Coral between these two features based on eq1 in this paper [1607.01719] Deep CORAL: Correlation Alignment for Deep Domain Adaptation which is for classification not semantic segmentation.

Any suggestions?