This data was collected by O2 on their customers, so I presume the data comes from what cell site you’re phone is connected to. To avoid this you’d need to have mobile data disabled or just leave your phone at home.
TfL collected a separate dataset themselves using WiFi access points in the underground (covered later in the article).