im triggering callback function witch reads encoder output with GPIO.add_event_detect so the global counter has current value, but i cant pass it to tkinter lik
I want to merge 2 dataframes without using the function '.merge' and I try to assign a value to a dataframe column based on an interval and an id. intervals = p
In the following code, I have defined a dictionary and then converted it to a dataframe my_dict = { 'A' : [1,2], 'B' : [4,5,6] } df = pd.DataFrame() df = df.app
I'm trying to send a message with discord, activated through a Flask endpoint I get the following error message when I call http://127.0.0.1:5000/send RuntimeEr
I'm using CoingGecko API for acquiring info about crypto. I have a function for getting a json from the API of crypto currencies. Then I upload the id of crypto
This is exactly what I am trying to re-create I've tried a 4x4 grid layout with QLabels underneath a QProgressBar but it looks awful and I am wondering if ther
As you can read on the title, I'm currently trying to make the code section collapsing without collapsing also the results section. For example without the coll
I am stuck with this code written in py2 on psychopy. I am not an expert with coding. I am trying to run the function "analyzeStaircases(stairs, stairInfo['Aver
I have a project to hand in which requires me to develop a program in python which would recognise handwritten numbers given in the form of image(i imagine the
Consider the following vector: import numpy as np u = np.random.randn(5) print(u) [-0.30153275 -1.48236907 -1.09808763 -0.10543421 -1.49627068] When we print
I have this dictionary of lists of dictionaries (I cannot change the structure for the work): dict_countries = {'gb': [{'datetime': '1955-10-10 17:00:00', 'city
Currently I am trying to solve the following problem: Ratiorg got statues of different sizes as a present from CodeMaster for his birthday, each statue having a
z = {'A': [0.3618426, 0.36146951], 'B': [1.8908799, 1.904695], 'C': [2.1813462e+08, 2.1833622e+08], 'D': [0.89925492, 0.89953589], 'E': [2.6356747, 2.6317911],
I am trying to migrate a program using python manage.py db migrate in my Visual Studio terminal but when I run it I am getting an error named (2005, "Unknown se
I have a really simple logic that I would like to understand how I can make it work in pyspark. for data in df1: spark_data_row = spark.createDataFrame(data
I would like to know, whether there is a pre-built function / package which does a simply OLS regression, by adding one independent variable from a pre-defined
I am currently learning to code with python in vscode but recently I have been having problems with file seemingly deleting themselves after attempted execution
I am running different machine learning models on my data set. I am using sklearn pipelines to try different transforms on the numeric features to evaluate if o
I am looking for a method that will look at each date in "Date A" and find the next nearest date after that value in "Date B" by ID (group_by). I then want to c
I defined the following model, which has two distinct outputs: input_layer = keras.layers.Input(shape = (1, 20), name = "input_features") # Shared layers hidde