Categories
Raspberry Pi User Help

import Spacy on RPI in Pycharm and other IDE gives error

I successfully installed Spacy using pip install spacy and alternatively through Pycharms virtual env, but when I import spacy in my program it’s giving me the following error; home/pi/.virtualenvs/cv/bin/python /home/pi/PycharmProjects/testSpeech/main.py Traceback (most recent call last): File "/home/pi/PycharmProjects/testSpeech/main.py", line 2, in <module> import spacy File "/home/pi/.virtualenvs/cv/lib/python3.7/site-packages/spacy/__init__.py", line 10, in <module> from thinc.neural.util import prefer_gpu, require_gpu File […]

Categories
Raspberry Pi User Help

import Spacy on RPI in Pycharm and other IDE gives error

I successfully installed Spacy using pip install spacy and alternatively through Pycharms virtual env, but when I import spacy in my program it’s giving me the following error; home/pi/.virtualenvs/cv/bin/python /home/pi/PycharmProjects/testSpeech/main.py Traceback (most recent call last): File "/home/pi/PycharmProjects/testSpeech/main.py", line 2, in <module> import spacy File "/home/pi/.virtualenvs/cv/lib/python3.7/site-packages/spacy/__init__.py", line 10, in <module> from thinc.neural.util import prefer_gpu, require_gpu File […]

Categories
Raspberry Pi User Help

Passing Integer through bash alias to python script/code

I have a Python script that reads the news through an RSS Feed. so the problem is that it only runs the news titles based on the hard-coded values in the code. So, what I did is I used sys.argv[1] in my py code to read the passed integer from CLI and it is working […]

Categories
User Help

Can’t connect to my public IP from other machine in same local network

I have recently set up port forwarding on my router so that it forwards incoming traffic at port 48888 to my laptop: I have set up static DCHP for my laptop so that it always has the same local IP, i.e. 192.168.0.35. From now on I’ll use 80.222.77.111 to refer to my public IP (though […]

Categories
Mastering Development System & Network

Python throws KeyError when exporting environment variables

I have a weird case where i have a secret.env file where i set all my environment variables as such: secret.env export TWITTER_CONSUMER_KEY="something" export TWITTER_CONSUMER_SECRET="something" Then i built a docker file to export all the variables and run the app as such: FROM python:3.8-slim-buster # Set the working directory to /app WORKDIR /app # Copy […]

Categories
Mastering Development

Error while using CTE on hive shell from spark

The query I use for the join is : WITH temp_cte AS (SELECT partition_date, appstate.viewid FROM table1 WHERE partition_date = ‘2020-10-10’) SELECT * FROM temp_cte AS t1 LEFT JOIN table2 AS t2 ON ( t1.view_id = t2.appstate.viewid AND t2.partition_date = ‘2020-10-10’ ) I get the following error : Error: Error while compiling statement: FAILED: ParseException […]

Categories
Mastering Development System & Network

AttributeError: module ‘openstack.proxy’ has no attribute ‘Proxy’

I’m runing an Ussuri install on openSUSE 15.2. According the official install guide, the Keystone, Glance, and Placemente has run withou any bigger issues. But, when i try run any command with nova-manage, i have that message: AttributeError: module ‘openstack.proxy’ has no attribute ‘Proxy’ That message occurs at every comand with "nova-manage". Especially, i’m executing […]

Categories
Mastering Development System & Network

Updated from CentOS 7 to 8 and broke everything

Everything was going smoothly until I decided to run dnf update and saw.. A lot of errors. They were all related to dependencies of things that needed to be installed that had mismatched versions. So, I removed the old versions of them. Which worked, until I needed to run the risky dnf –setopt protected_packages= shell […]

Categories
Mastering Development

Align Tkinter radio buttons

My Tkinter radio buttons are misaligned. I have tried this Python tkinter align radio buttons west, this Python tkinter align radio buttons west and none of them worked, what I see is this when I use grid to manage the widgets (has to be grid as it is part of a larger UI). I have […]

Categories
Mastering Development System & Network

broken dnf in CentOS 8

I keep getting the following error whenever I do a dnf update -y or try to install a package. I’m using CentOS 8 as a virtual machine. Can you tell me why this is happening? Traceback (most recent call last): File "/usr/lib64/python3.6/site-packages/libdnf/common_types.py", line 14, in swig_import_helper return importlib.import_module(mname) File "/usr/lib64/python3.6/importlib/__init__.py", line 126, in import_module return […]