The article analyses physicists’ attitudes towards philosophy on the examples of the positions of eminent theorists. There are two physicists’ philosophical attitudes towards philosophy: pro-philosophical (Einstein, Bohr, Heisenberg, von Weizsäcker, Penrose, Rovelli) and anti-philosophical (Weinberg, Hawking, Feynman). I analyse some physicists' arguments for or against philosophy. It is demonstrated that physicists are most critical of all philosophical conceptions that accept a priori factors in cognition, while those who recognize the significance of philosophy for science most often refer to the Pythagorean-Platonic tradition as the proper basis for understanding modern physics.