I am using a library called mojimoji to convert half-width characters to full-width characters.
I want to execute code using this library in Jupyternotebook.
Here's the Jupyternotebook
When I try to import the library, I get the following error:
Applicable source code
import MeCab import mojimoji -------------------------------------------------- ------------------------- ModuleNotFoundError Traceback (most recent call last) <ipython-input-2-c3dcc64cddab>in<module>() 1 import MeCab ---->2 import mojimoji ModuleNotFoundError: No module named 'mojimoji'
When you run the code from the terminal, it will run without problems.
Supplemental information (FW/tool version etc.)
>>>import mojimoji >>>text = "Nihonko" >>>text = mojimoji.han_to_zen (text) >>>print (text) Japanese
Python 3.6.0 :: Anaconda 4.3.0
Answer # 1
Isn't Python running differently?
import sys sys.prefix sys.executable
Does the result match in the interaction environment between Jupyter and the terminal?
Terminal dialogue environment,
import mojimoji mojimoji .__ file __
Where do the files appear after running
(sys.prefix directory) /lib/pyhton3.6/site-packages/mojimoji. ??????. Soin the terminal's interactive environment?
Isn't you running jupyter notebook from the terminal to launch Jupyter Notebook and using another method (Launchpad?)?
The conclusion is that anaconda installed from pyenv and anaconda installed by anaconda installer coexist.
The Jupyter Notebook you're looking at is from the anaconda installer.
The terminal starts pyenv's anaconda, so mojimoji also entered pyenv's anaconda.
It is not possible to use from Jupyter Notebook because there is a conflict.
If you have installed with the anaconda installer, you should just use the pyenv to erase it.
You can start Jupyter Notebook from the terminal with
- macos (osx) - about firebase cli installation
- macos (osx) - how does a hidden folder (~/library etc) that does not start with (dot) on macos work?
- macos (osx) - local installation of firefox add-on
- macos (osx) - app installation on mac
- macos (osx) - after inserting fish, the terminal of mac doesn't start
- macos (osx) - is it possible to customize the contents displayed in help with the application of macos?
- macos (osx) - mac becomes a white screen and cannot start it cannot be initialized is there a way to recover?
- macos (osx) - differentiated difference approximation unknown print function syntax error invalid syntax cause unknown
- macos (osx) - i am creating an app for mac with swiftui, but i know how to display another window, but an error occurs when i cl
- macos (osx) - how to install macports terminal
- macos (osx) - i can't install pygame on mac
- macos (osx) - vagrant file cannot be generated
- macos (osx) - i want to run sublime with the subl command : macos
- macos (osx) - the view is not displayed after i accidentally loadview
- macos (osx) - how to solve the error in sublime text
- macos (osx) - vagrant up cannot be executed normally
- macos (osx) - location of import 〇〇
- macos (osx) - unable to ssh connect to sakura vps
- macos (osx) - i would like to ask about mac files
- macos (osx) - how to exceed the upper limit of accessibility reading function
- i want to import readline only in mac environment with python
- python 3x - i want to calculate spearson's rank correlation coefficient and p-value for a two-variable data set obtained from ex
- matplotlib display circles at regular intervals
- python 3x - jupyter notebook drawing
- python: i want to write the xlsx name (csv name) read in the data frame in a column
- opencv - about the processing result when the size is set to 0 in the bilateral filter cv2bilateralfilter
- i want to quickly copy and rename excel files with python
- python 3x - about use of decision tree in anaconda
- python 3x - construction of jupyter notebook environment on raspberry pi4
- python - how to start jupyterlab in terminal