PyCharm - Defining custom recognized import aliases?

Viewed 911

In PyCharm, I can type np.array, and if I haven't imported NumPy yet, PyCharm gives me a simple click to automatically write the import line. In particular, PyCharm knows that np is referring to numpy and will add the appropriate import numpy as np.

Is there a way to define my own alias names to be recognized? For example, tensorflow is usually imported as tf. PyCharm doesn't know this by default though, and so doesn't give me the automatic import completion. Any way to do this? Thanks you much!

0 Answers
Related