CREDIT AGREEMENT between TerraForm Power, Inc., as Borrower, and Brookfield Asset Management Inc. and Brookfield Finance Luxembourg S.à r.l., as Lenders Dated as of October 16, 2017