I've come across many such situations where I have used in built functions or modules where the syntax is sometimes "X.func\_name" and other times (X.func\_name()".

For example : 
In Pandas "df.columns" gives names of all columns and throws and throws error if written by mistake as "df.columns()" #TypeError: 'Index' object is not callable.

Also in Pandas, "count()", "min()" etc are written as df.count() | df.min()

I hope I have explained my question properly.

I believe it has something to do with the OOP concept of Class and it's member functions but I'd like a more in-dept understanding.