物体検出で、検証時に使う時にこんなエラーが出た。
TypeError: 'numpy.float64' object cannot be interpreted as an integer
TypeError: object of type <class 'numpy.float64'> cannot be safely interpreted as an integer.

別のレポジトリのところで解決策が書いてあった。レポジトリ独自のコードではなく、COCO API に問題があるそうで、numpy のバージョンを 1.18. から 1.17 に下げれば解決するとのこと。確かにソースをたどると、COCOeval
という関数を実行していた。
https://github.com/facebookresearch/detectron2/issues/580
!pip install numpy==1.17.5
で解決。感謝。