• Register

Recent questions tagged x

0 votes
1 answer 7 views
Problem : I just installed Python 3.5 and upon running the following code pip install mysql-python I am getting an error, which says: error: Microsoft Visual C++ 14.0 is required (Unable to find vcvarsall.bat) I have used the following lines of code to my PATH C:\ ... (x86)\Microsoft Visual Studio 12.0\VC; C:\Program Files (x86)\Microsoft Visual Studio 11.0\VC My PC has 64bit window 7 setup.
asked Oct 8 sikandar 2.4k points
0 votes
1 answer 89 views
Problem: I have only basic knowledge in python and urllib. Currently I am trying to write the program which should download the mp3's from the website and after that join them together but on every occasion I try to download the mp3 files I face below error: Traceback ( ... usc.edu/~chiso/oldspice/m-b1-hello.mp3") Looking for the python and urlllib expert who can help me in fixing my above error.
asked Jul 22 Raphael Pacheco 4.9k points
0 votes
1 answer 56 views
Problem: I have freshly migrated my project from the old python2 to the new python3 and it has hundreds of the ForeignKey relations. I have very basic knowledge related to python. Using a solution to go line by line and add on_delete argument is not the possible. What ... it does not look like catching it somehow. Looking for a Python expert who can try to fix my above Python error very quickly.
asked Jul 15 Raphael Pacheco 4.9k points
1 vote
1 answer 31 views
Problem : I want to learn the python programming and also want to work on projects. One of my projects is to code the voting system so that it can select the best player among 23 players of a match by using the lists. I am currently using the Python3. Please ... any of the strings in my above code all my variables are of the type integers. Please guide me in fixing above python related error.
asked May 14 Martin K 6.6k points
1 vote
1 answer 139 views
Problem : I am beginner to Python. Currently if I try to use the request module to have the urls text then I often face below Error: Traceback (most recent call last):  File "/usr/local/lib/python3.6/site-packages/requests-2.18.1-py3.5.egg/requests/adapters.py" ... to get the url's text to parse it. Please find below my line of code for your reference: mytext = requests.get(detail_path).mytext
asked May 2 stewart 4k points
1 vote
2 answers 312 views
Problem : I am beginner to Ancaconda3 and Tensorflow. I have also recently installed Ancaconda3 and Tensorflow. But if I try to import the Tensorflow in the python shell then I often face the below error: ModuleNotFoundError: No module named 'numpy.core._multiarray_umath ... also installed on my box and it can be very successfully imported in the python. Please note currently I am using Windows10.
asked Apr 22 stewart 4k points
1 vote
3 answers 2.2K views
Problem : I am very new to Python. Now I am trying to import my function from the another file in a same directory. I am able to do it sometimes with the use of .mymodule import myfunction but most of the times I face below error: Importerror: attempted relative ... . It seems completely random to me. I am looking for someone who is expert in Python and who can help me in fixing above error.
asked Apr 20 stewart 4k points
1 vote
2 answers 2K views
Problem : I am very new to Python. Currently I have one textfile and now I am trying to load it and then want to make the list which should contain each and every line from the text file. I have already tried to use the split() procedure. But I am facing ... I have already wasted a lot of time in understanding and finding workaround for above error.So I am looking for the quick fix on above error.
asked Apr 8 morrisBson 3.2k points
1 vote
2 answers 208 views
Problem : I am beginner to numpy. I am trying to execute my code but I am facing below error. “Valueerror: all the input arrays must have same number of dimensions”. I want to have my all the arrays with a same shape. I am trying to fix above error from past couple of days but still unable to fix it. I am looking for some help in fixing above error.
asked Apr 4 morrisBson 3.2k points
1 vote
1 answer 128 views
Problem: Hi all This is a question from a noob who started coding a few hours back. print("Hello") print("name") print("hello") print("Let's do some math!") print(5 + "a") print("5 + 5") print("Thanks for playing along!") It says, “typeerror: unsupported operand type(s) for +: 'int' and 'str'” What does it mean?
asked Mar 9 Gavin 15.3k points
1 vote
1 answer 22 views
Problem: I have multiple files that I need to load so I'm using a dict to shorten things. When I run my code it throws me back an error “ type' object is not subscriptable ” m1 = pygame.image.load(dict[1]) m2 = pygame.image.load(dict[2]) m3 = pygame. ... "walk3.png"} playerxy = (375,130) window.blit(m1, (playerxy)) I am not sure about the error. Where is the problem in my program?
asked Mar 8 Gavin 15.3k points
0 votes
2 answers 75 views
Problem : I have recently installed the cuda 8.0 and cuda 9.0 in the Gpu support system. I encountered the below error while importing from the keras module. It says it is unable to load the native tensorflow runtime. I have received the error log as below: Traceback ... is, Cuda compilation tools, release 8.0, V8.0.61 Is it the clash between two cuda versions? Have anyone solved this before?
asked Feb 18 mphil 2.3k points
0 votes
1 answer 396 views
Problem : Please find below my code for your reference. import os for root, dirs, files in os.walk('Path'):      for file in files:          if file.endswith('.c'):              with open(os.path.join(root, file)) as f:                     for line in f: ... already tried setting it with the open(os.path.join(root, file),'r',encoding='cp932') as f: but got the same above error
asked Jan 31 jwilliam 3.9k points
0 votes
1 answer 92 views
Problem : I am unable to understand what am I missing here: Sort my_short_names in reverse alphabetic order. The sample output from the given program as below : ['Tody', 'Samy', 'Joey', 'Jany', 'Anny'] Below is my code for your reference : my_short_names = ['Jany', 'Samy', 'Anny', 'Joey', 'Tody'] my_short_names.sort() print(my_short_names)
asked Jan 8 alecxe 7.5k points
0 votes
1 answer 613 views
Problem : When I am trying to execute jupyter notebook in the virtual environment in my Arch Linux, the below error occurred. “Error executing Jupyter command 'notebook': [Errno 2] No such file or directory” The python version is 3.6, and the jupyter version is 4.3.0 I have researched a lot, but I am just unable to find anything relevant to above issue.
asked Jan 3 alecxe 7.5k points
0 votes
1 answer 1.6K views
Problem : MySample.csv contains the below details : NAME Id No Dept Tommy 1 12 CS Jimmy 2 35 EC Bonny 3 21 IT Franky 4 61 EE And my Python file contains the below code : import csv myifile = open('mysample.csv', "rb") read = csv.reader(myifile) for row in read : ... in for row in read : _csv.Error: iterator should return strings, not bytes (did you open the file in text mode?) How should I fix it?
asked Jan 2 alecxe 7.5k points
0 votes
1 answer 550 views
Problem : I am trying to use the PyGame for Python, and I have been receiving the below warning while trying to load .png images with pygame.image.load: Libpng warning: Interlace handling should be turned on when using png_read_image It is not affecting the program, but it has become ... : I am currently using 32 bit Python 3.3 with the PyGame 1.9.2 Any pointers as to how can I fix the warning?
asked Jan 2 alecxe 7.5k points
0 votes
1 answer 214 views
Problem : When I try to run following command: python manage.py updatestats I get the error as below: “TypeError: int() argument must be a string, a bytes-like object or a number, not 'list'” I am unable to figure out ... ) File "/Users/alecxe/project/Dev/project_files/project/main/management/commands/updatestats.py", line 34, in handle unique_visits=display_unique_visits(hostname),)
asked Jan 2 alecxe 7.5k points
0 votes
1 answer 1.6K views
Problem : I am at my minds end. After a lot of hours of troubleshooting, probably more than 20, I thought I was finally in business, but then I got following error : Model class django.contrib.contenttypes.models.ContentType doesn't ... class MyDeletenoteConfig(AppConfig): name = 'MyDeleteNote' and from django.apps import AppConfig class MyLibrarysyncConfig(AppConfig): name = 'MyLibrarySync'
asked Dec 16, 2019 alecxe 7.5k points