I have simple function for which I want to calculate the minimum value from scipy import optimize def f(x): return x**2 optimize.fminbound(f, -1, 2) This
I've made an Flask API Server that i want to run on a Server and close the Terminal session and still keep it running. (SSH) The API's makes a lot of Requests t
I'm in need of some assistance in this code problem from a MOOC on python programming that I'm taking. This is just for self-learning, and not for any graded co
I connected my laptop to a Vector Network Analyzer (VNA) by a GPIB cable. I identified the instrument to the laptop by the following code in Jupyter Notebook: f
I am trying to connect to memsql (running as docker container - cluster-in-a-box). I am using Python3.9. Tried with Python 3.8 as well. Here is the code snippet
In Python, I have a dataset like this below, where column1 and column2 are objects and not strings: data = {'id': ['first_value', 'first_value', 'second_value'
I have the following network graph. # Create the graph with unique edges to check the algorithm correctness G = nx.MultiGraph() G.add_edge('A','B',route='56BM',
This attribute error appeared when I try to run my code using Gtk and Python. Would anyone know how to solve it? This is my code: import gi gi.require_version('
https://kivymd.readthedocs.io/en/latest/components/bottomnavigation I tried to apply material design 3 in KivyMD project. I ran the example code on the KivyMD
I am doing a textbook problem and I am trying to understand how regex works with Python. In python, I tried doing: "(aa)*|(bb)*" I seem to be accepting any stri
I am trying to call a package and a module but it throws an error. the modules are from DB_Manager* import from Operate_System.OS_Resolution import* but it gen
I am Making a Music discord bot and I have been trying to make it loop and queue songs. But when I try to queue a song it just starts playing it instead of queu
I am trying to figure out how to add row entries of the numeric columns(supply,demand) . I am at a complete loss. My initial thoughts are to do this with a dic
I have the following code to evaluate some configuration values stored in a file: from ast import literal_eval for key, value in dict_read_from_file.items():
I have a df made of values from a dictionary. I can get rid of [], ',' and split it all in different cols (one col per number). But can't make the transfer to f
Let's say I'm writing a lifespan prediction calculator that takes in ~40 inputs: sex = ['Male', 'Female'] smoking_status = [True, False] ... Eventually, there
I have a nested dictionary. How do I access them and get the result as follows: dict_lbl = { "lbl1":{"name":"label1","item1":"Accounts", "item2":"kannagu"
I have model with manytomany field and the task is to make an validation in model layer. When i run this code, this error occurs: ValueError at /admin/main/boss
I ran a series of simulations and want to create a response surface of the performance based off my two parameters, tol and eta. The issue I'm having is actuall
We want to have a distributed transaction publishing between two ActiveMQ brokers. The ActiveMQ documentation states they support XA transactions. Our code base