Babur (reigned 1526–30), the founder of the Mughal dynasty, acquired Agra after defeating the Lodhis and the Tomaras of Gwalior in the First Battle of Panipat in 1526. Babur's connection with Agra began immediately after the battle of Panipat. He sent forward his son Humayun, who occupied the town without opposition. The Raja of Gwalior, slain at Panipat, had left his family and the heads of his clan at Agra. In gratitude to Humayun, who treated them magnanimously, and protected them from plunder, they presented to him a quantity of jewels and precious stones as a token of homage. Among these was the famous diamond Koh-i-nur. Babur went on to lay out the first formal Mughal garden in India, the Aram Bagh (or Garden of Relaxation) on the banks of the river Yamuna. Babur was determined to establish the seat of his government at Agra, but was almost dissuaded by the desolate appearance of the region, as clear from this quote from his memoir "Baburnama":