Questions tagged as 'python'

1
answer

Search for all tags that begin with a given chain

I'm doing a scrapy for a page where I'm looking for a label. I do it with BeautifulSoup. I look for all the links that start with them, but end up differently. Example: for url in soup.find_all('a', href=("/es/nds/*******")): Where the...
asked by 13.01.2018 / 12:58
1
answer

Doubt with .show () from matplotlib

Working with matplotlib to generate graphs, I do not quite understand the difference between these two ways of generating and displaying a graph. I have read documentation about it, but it has not been clear to me. Form 1: import matplotlib...
asked by 10.01.2018 / 14:11
3
answers

Increase days to a given date with nested arrangement

I am a beginner in Python and I am trying to make a program that reads a date ( AAAA-MM-DD ) given by the user and allows me to show 5 days subsequent to the given date and to make the changes of day, month or year in his case Any ideas? I...
asked by 10.01.2018 / 19:52
3
answers

Python - List of disordered and repeated colors

Hi, I'm doing a program that has a list of repeated and messy colors. I want to know which of those colors is the most repeated and in its case return the most repeated color and the number of times. There is a particularity, if there are severa...
asked by 09.01.2018 / 16:46
1
answer

Pandas convert non-null objects

After importing using urlib , Internet data, I can create a DataFrame (df) with two columns (Fecha y Valor) of the types: Fecha 1563 non-null object, Valor 1563 non-null object. With the statement df["Fecha"] =...
asked by 15.01.2018 / 13:02
1
answer

Problem executing an .exe with pyinstaller

Bunas, I tell you my problem, when working with the package anaconda3-4.2.0 x86 for windows 10 x64 I could generate my .exe program and it worked correctly. Then I had to format my PC for some problems and install the same version of widows 10...
asked by 12.12.2017 / 20:13
1
answer

How can I activate an object in Blender with Python

From a Python script I want to activate an object in order to enter editing mode and edit it. To select the desired object I use bpy.context.scene.objects["Nombre_objeto"].select = True # (1) What happens is that if before selecting the ob...
asked by 30.04.2018 / 18:55
1
answer

Replace characters of a string in python using Lists

Good! I try to make my script go through a string and replace each character with another string using lists to be able to change each of the characters in a simpler way, but when going through my list it does not replace them beca...
asked by 27.11.2017 / 02:22
1
answer

How to remove specific elements within a matrix in Python?

I did not know how to be more specific in the title, but the problem is that I'm doing a code for the problem of isomorphism of subgraphs (quite basic the truth), and I have a problem, I need to "decompose" a matrix, with this I mean the followi...
asked by 02.05.2018 / 18:44
2
answers

"NoReverseMatch at" error with "django.contrib.auth.views.login" tests

I would like to authenticate users using django.contrib.auth.views.login . I want that when the login is correct I send them to dashboard . I have the following codes: In settings: LOGIN_REDIRECT_URL = '/usuarios/dashboard/'...
asked by 19.01.2016 / 13:06