The balance of training data between classes for a machine learning model is modified. Adjustments are made at the gradient stage where selective backpropagation is utilized to modify a cost function to adjust or selectively apply the gradient based on the class example frequency in the data sets. The factor for modifying the gradient may be determined based on a ratio of the number of examples of the class with a fewest members to the number of examples of a present class. The gradient associated with the present class is modified based on the above determined factor.
Please help me write a proper abstract based on the patent claims. CLAIM: 1. A method of modifying a balance of training data between classes for a machine learning model, comprising: modifying gradients of a backpropagation process while training the model, based at least in part on a ratio of a number of examples of a class with a fewest members to a number of examples of a present class. 2. The method of claim 1, in which the modifying comprises scaling the gradient. 3. The method of claim 1, in which the modifying comprises selectively applying the gradient based at least in part on a sampling of the class examples. 4. The method of claim 3, in which the sampling of the class occurs by selecting a fixed number of examples from each training epoch. 5. The method of claim 1, in which the sampling occurs without replacement of examples in a training epoch. 6. An apparatus for modifying a balance of training data between classes for a machine learning model, comprising: means for determining a factor for modifying a gradient based at least in part on a ratio of a number of examples of a class with a fewest members to a number of examples of a present class; and means for modifying the gradient associated with the present class based on the determined factor. 7. The apparatus of claim 6, in which the modifying means comprises means for scaling the gradient. 8. The apparatus of claim 6, in which the modifying means comprises means for selectively applying the gradient based at least in part on a sampling of the class examples. 9. The apparatus of claim 8, in which the sampling of the class occurs by selecting a fixed number of examples from each training epoch. 10. The apparatus of claim 6, in which the sampling occurs without replacement of examples in a training epoch. 11. An apparatus for modifying a balance of training data between classes for a machine learning model, comprising: a memory; and at least one processor coupled to the memory, the at least one processor configured to modify gradients of a backpropagation process while training the model, based at least in part on a ratio of a number of examples of a class with a fewest members to a number of examples of a present class. 12. The apparatus of claim 11, in which the at least one processor is configured to modify by scaling the gradient. 13. The apparatus of claim 11, in which the at least one processor is configured to modify by selectively applying the gradient based at least in part on a sampling of the class examples. 14. The apparatus of claim 13, in which the sampling of the class occurs by selecting a fixed number of examples from each training epoch. 15. The apparatus of claim 11, in which the sampling occurs without replacement of examples in a training epoch. 16. A non-transitory computer-readable medium for modifying a balance of training data between classes for a machine learning model, the non-transitory computer-readable medium having program code recorded thereon, the program code comprising: program code to modify gradients of a backpropagation process while training the model, based at least in part on a ratio of a number of examples of a class with a fewest members to a number of examples of a present class. 17. The non-transitory computer-readable medium of claim 16, in which the program code to modify comprises program code to scale the gradient. 18. The non-transitory computer-readable medium of claim 16, in which the program code to modify comprises program code to selectively apply the gradient based at least in part on a sampling of the class examples. 19. The non-transitory computer-readable medium of claim 18, in which the sampling of the class occurs by selecting a fixed number of examples from each training epoch. 20. The non-transitory computer-readable medium of claim 16, in which the sampling occurs without replacement of examples in a training epoch.