the best way is to open your IDE on the same terminal where u had sourced the setup file before.
the package is'nt recognized outside ROS, as these are installed in the site-packages folder that lies within ros2 directory.