Questions tagged as 'python-3.x'

0
answers

Problem in compiling code in Keras

I was creating a simple classifier in Keras in Python3, but I'm getting the same error message:    RuntimeError: You must compile your model before using it. Follow the code: import keras from keras.layers import Activation, MaxPooling2...
asked by 26.06.2018 / 23:00
0
answers

Move to url with an increment in address

I need to do a crawler on a book site. I can get the data I need from a page and I also got the entire domain, but I wanted to do it in a more orderly and logical way. I'd like to start by extracting for a URL and letting the code go through...
asked by 29.06.2018 / 01:08
0
answers

Relating button made in Tkinter, with graph generated in matplotlib

Good evening! I have the following code, which calls an excel table and converts it to a bar chart: import openpyxl import matplotlib.pyplot as plt book = openpyxl.load_workbook('planilha.xlsx') sheet = book.active celulas = sheet['A2':'B8...
asked by 29.06.2018 / 01:14
1
answer

How to clear fields from a form in Django

I'm studying Django and I'm following a course, which is setting up a Spending Control. However I am not 100% faithful to the course, I am making some modifications. My problem is this, when I register a transaction, the form fields are not clea...
asked by 04.07.2018 / 02:38
0
answers

'int' object is not subscriptable

I have a problem with the following code: for x0 in range(len(matriz)): # Abaixo foi aplicada a fórmula de transformações lineares para linhas e colunas. xn = transformação[0][0] * x0 + transformação[0][1] * x0 + y0 + transformação[0][2]...
asked by 23.06.2018 / 05:21
1
answer

How to save in CSV or Excel a table generated from another table with pandas or pivot table?

I have a table with data for several years from 2000 to 2015 in CSV format. In my code I ask the user to type a year that he wants to see and return on the screen only the years he requested. Ex .: 2000. And I want this data to be saved in a...
asked by 24.06.2018 / 23:19
0
answers

Generate ctypes._fields_ dynamically

Good afternoon guys! This is my first post here, so have patience with the newbie;) I am creating a DNS server taking into account the RFC 1035 specifications using the ctypes to improve code readability and make it more organized. My...
asked by 25.06.2018 / 19:46
1
answer

Question of lists python3 Conway Game of Life

Good afternoon everyone! I am currently working on a diagram, where each element is a list. For the list entry, I made the following command line: diagrama_entrada=[] x=True while x: l=input() if not l....
asked by 14.06.2018 / 18:19
1
answer

How do I get and save many data entries in python?

I'm starting to program and so far the data entries were like this: dado_1 = str(input('Seu nome: ')) dado_2 = int(input('Sua idade: ')) dado_3 = str(input('Sexo: ')) But I was left with a doubt, as I take the same data as above...
asked by 13.06.2018 / 01:00
0
answers

Result of paged rather than unified loop

I'm having trouble getting a formatted result in paged JSON. My code instead of returning the result of the bound, is bringing the result per page! import requests def __init__(self, usuario, token): self.usuario = usuario self.token...
asked by 07.06.2018 / 01:18