  Domain generalization aims to address the domain shift between training and
testing data. To learn the domain invariant representations, the model is
usually trained on multiple domains. It has been found that the gradients of
network weight relative to a specific task loss can characterize the task
itself. In this work, with the assumption that the gradients of a specific
domain samples under the classification task could also reflect the property of
the domain, we propose a Shape Guided Gradient Voting (SGGV) method for domain
generalization. Firstly, we introduce shape prior via extra inputs of the
network to guide gradient descending towards a shape-biased direction for
better generalization. Secondly, we propose a new gradient voting strategy to
remove the outliers for robust optimization in the presence of shape guidance.
To provide shape guidance, we add edge/sketch extracted from the training data
as an explicit way, and also use texture augmented images as an implicit way.
We conduct experiments on several popular domain generalization datasets in
image classification task, and show that our shape guided gradient updating
strategy brings significant improvement of the generalization.
