Defect synthetic data generation

I want to generate defect data, for example, I have a car CAD model with scratches as a separate mesh, and my requirement is to train a deep-learning model. For this only annotations of scratches should be saved along with the whole car pictures with scratches on them not just the pictures of scratches. Please help me with python scripting as no such tutorial is available.