Not able to run sweeps in Pycharm

I ran into error while running sweep in Pycharm. The error messages just don’t make sense, like sklearn modulenotfound error. When I changed the code to a minimal one to just log a variable, the error is like wandb has no attribute init etc. I am using .yaml file to create sweep.

The code works locally.

It’s all very frustrating. Just wanted to know if sweep work with pycharm?