It takes our custom YAML-formatted code and generates source code for each method by processing it through a series of steps using a number of plugins.

How does PyTorch's build system take all of these components to compile and generate a workable application?

It takes a bunch of source/header files, libraries, and compilation directives to build an extension using Setuptools.
This is just a snapshot of parts of the build system for PyTorch. There is more nuance, and detail, but I hope this serves as a gentle introduction to a lot of the components of our Tensor library.
Resources:

https://docs.python.org/3.7/extending/index.html is invaluable for understanding how to write C/C++ Extension to Python
