Pip nltk安装说明目录不属于当前用户,并且要求已经是最新的

Pip nltk安装说明目录不属于当前用户,并且要求已经是最新的,pip,nltk,sudo,Pip,Nltk,Sudo,我正在尝试使用sudo pip nltk安装nltk,但由于以下错误而停止: The directory /users/$username/library/caches/pip/http or its parent directory is not owned by the current user and the cache has been disabled. The directory /users/$username/Library/Caches/pip or its parent

我正在尝试使用sudo pip nltk安装nltk,但由于以下错误而停止:

The directory /users/$username/library/caches/pip/http or its parent directory is 
not owned by the current user and the cache has been disabled. 
The directory /users/$username/Library/Caches/pip or its parent directory is 
not owned by the current user and caching wheels has been disabled. 
Requirement already satisfied: nltk in /Library/Python/2.7/site-packages (3.3)
Requirements already satisfied: six in /System/Library/Frameworks/Python.framework/Versions/2.7/Extras/lib/python (from nltk) (1.4.1) 
显示了这些错误消息,我不知道是否已经有nltk并且是最新的。我检查了所有父目录的权限,并且所有目录都有drwx,所以我不明白为什么仍然显示该消息


请帮忙!我被这个问题困住了,我想我在某个时候把我的系统Python搞砸了

使用sudo-H pip install-U nltk解决了问题

pip install--user-U nltk
@alva它说“ImportError:没有名为pip的模块。\U internal”?