jupyter

Array conditional must be same shape as self

我的未来我决定 提交于 2021-02-05 09:38:28
问题 I get this error when I attempt to compare to variable names such as: compare = Search1.where(Search1UK>Search1DE) compare compare.fillna(0) 'Search1UK' and 'Search1DE' are both variable names in which I have assigned a name to identify columns within different data frames. Anyone could help on this please? 回答1: try: compare = Search1.where(Search1['Search1UK']>Search1['Search1DE']) 来源: https://stackoverflow.com/questions/55163796/array-conditional-must-be-same-shape-as-self

Why can't I find this string in RegEx?

橙三吉。 提交于 2021-02-05 06:39:46
问题 lines = [] total_check = 0 with pdfplumber.open(file) as pdf: pages = pdf.pages for page in pdf.pages: text = page.extract_text() for line in text.split('\n'): print(line) output data: Totaalbedrag excl. btw € 25,00 When I try to retrieve VAT from data: KVK_re = re.compile(r'(excl. btw .+)') KVK_re.search(data).group(0) output: AttributeError: 'NoneType' object has no attribute 'group' KVK_re = re.compile(r'(excl. btw .+)') KVK_re.search(r'excl. btw € 25,00').group(0) output: 'excl. btw € 25

Can you run Google Colab on your local computer?

房东的猫 提交于 2021-02-04 21:28:08
问题 My PC is rocking a 2080TI so I don't really need the GPU computation of Google Colab, but I do find it a nice development environment (in comparison to jupyter notebooks) and I like the fact that I can access my files from anywhere, so, is it possible to use Google Colab but let my local pc do the computation? 回答1: Steps: Go to Google colab and click on connect to local runtime, a pop-up comes. Go to your terminal and execute: jupyter notebook --NotebookApp.allow_origin='https://colab

Giant IPKernelApp Error Using Hydrogen in Atom

﹥>﹥吖頭↗ 提交于 2021-02-04 21:05:55
问题 Starting a few days ago, after months without issue, I began having a giant error box keep popping up when editing my code in Atom. I believe it is from the Hydrogen plugin, the weird thing is even with this error the code still runs and does what I want it too. I created a new conda environment, installing only what I needed (pandas, geopandas, descartes, jupyter) and even when using the new environment in Atom I am getting this issue. I've tried upgrading ipykernel but it is already the

Giant IPKernelApp Error Using Hydrogen in Atom

强颜欢笑 提交于 2021-02-04 21:01:52
问题 Starting a few days ago, after months without issue, I began having a giant error box keep popping up when editing my code in Atom. I believe it is from the Hydrogen plugin, the weird thing is even with this error the code still runs and does what I want it too. I created a new conda environment, installing only what I needed (pandas, geopandas, descartes, jupyter) and even when using the new environment in Atom I am getting this issue. I've tried upgrading ipykernel but it is already the

How to Fix: “ImportError: DLL load failed The specified procedure could not be found.” when the DLLs are there

余生长醉 提交于 2021-02-04 05:53:06
问题 Updated to new Anaconda 2018, opened a jupyter notebook that worked prior to the update. Having problems with loading seaborn into the script. Tried following several threads on this but nothing worked question. I've tried: -Setting Enviromental Variables -Reinstalling Anaconda2018 -Uninstalled and reinstalled seaborn using conda -Reinstalled SciPy Running out of options as I want to use Seaborn 0.9.0 and python-3.7 but I cannot seem to get 3.7 to play with 0.9.0. Help? import seaborn as sns

vscode can't open Python interactive, and the following error occurs

只愿长相守 提交于 2021-01-29 18:55:18
问题 When using vscode, can't open Python interactive, and the following error occurs: Activating Python 3.7.3 64-bit to run Jupyter failed with Error: Command failed: D:\software\anaconda\activate base && echo 'e8b39361-0157-4923-80e1-22d70d46dee6' && python c:/Users/HELLO/.vscode/extensions/ms-python.python-2019.11.50794/pythonFiles/printEnvVariables.py 'D:\software\anaconda\activate' 回答1: I'm a developer on the data science features for this extension. There are currently some issue with conda

VSCode Jupyter Notebook - Restore Cache Version

为君一笑 提交于 2021-01-29 17:50:33
问题 I was creating a Jupyter Notebook using VSCode (v 1.48.0) running on Ubuntu 19.10. VSCode crashed and unfortunately I had not saved the notebook, and when I restarted it was empty. I have been able to find what looks like a cached version of the notebook in ~/.config/Code/User/globalStorage/ms-python.python , in a file called 527ed533.ipynb. Small sample of what the file looks like Reviewing the contents of the file, I can tell that this is the notebook I was working on, but the format looks

Problems with Jupyter python kernel

徘徊边缘 提交于 2021-01-29 16:20:20
问题 I have been looking to use Jupyter for some upcoming projects and decided to go ahead and set it up. When I select the "Python" under kernels when creating a new notebook, the following error occurs. Traceback (most recent call last): File "C:\Users\thoma\AppData\Local\Packages\PythonSoftwareFoundation.Python.3.7_qbz5n2kfra8p0\LocalCache\local-packages\Python37\site-packages\tornado\web.py", line 1699, in _execute result = await result File "C:\Users\thoma\AppData\Local\Packages

Jupyter / IPython SList :: Obtaining non-tokenized output from the shell execute operator “!”

风格不统一 提交于 2021-01-29 15:11:47
问题 When shell commands are run within a Jupyter Notebook Python Cell , like this: output = ! some-shell-command each line emitted to the standard output ( stdout ) is captured in a list like IPython data-structure called a SList . For instance: output = !echo -e 'line1\nline2\nline3' print(output) # A IPython SList data-structure. ['line1', 'line2', 'line3'] Sometimes, however, you want to preserve the original string output format, without tokenization into a list, like this: print(output)