Quantcast
Browsing all 13981 articles
Browse latest View live

Fast Implementation of the 1 Parameter Division Distortion Model

I have implemented some code that allows me to estimate the center of distortion for an image along with a distortion parameter that attempts to remove any radial distortion present in the image. It is...

View Article


Issue with Prediction Shape in Hugging Face Accelerated Inference

I am currently facing an issue while utilizing the Hugging Face accelerator for inferencing on a test dataset.The code snippet below outlines my inferencing process, where I have four GPU devices, and...

View Article


matplotlib.image.imread(): Some images are integers while some others are floats

I am trying a script that works with images in python.The first image was working and the second one did not work at all.The script wasimport matplotlib.pyplot as pltimport matplotlib.image as...

View Article

How o get the xPATH of the "Like" button from Facebook

I want to ask how to get the XPath of the “Like” button of facebook?how to click on XPath using selenium and chromdriveri need help. thank youI have tried many times from taking XPath, changing the way...

View Article

How to detect and read DTMF input values from Asterisk AMI by using python...

I have some problem in making python script for the calling system based on Asterisk.I makes it to make phone call and detect DTMF input values from Asterisk.Now it works well with the origination of...

View Article


How to remember data? [closed]

I'm developing sort of a scheduler script to write the repetition intervals for me using google sheets API and I can't be constantly running the app, so the next time I run it it doesn't remember which...

View Article

Streaming with Langchain - `astream` method in Langchain doesn't return an...

I am working on a FastAPI application that should stream tokens from a GPT-4 model deployed on Azure. I want to create a FastAPI route that uses server-side events to stream each token as soon as it's...

View Article

How can I sort by a column while binning another

I am trying to cut float values of each country while grouping them by continent.This is the code that I wrote out:groups = renew.groupby(['Continent'],pd.cut(renew['% Renewable'], 5))Bug I am getting...

View Article


Quart: sync vs async parsing form data

I'm investigating the performance of uploading files to the Quart web serverI'm looking at how Quart parses file data when the request type is "multipart/form-data", and I see that synchronous...

View Article


Problem with uploading video to youtube by Youtube Data API V3

i'm trying to upload a short video to my channel by a python script using "Youtube Data Api v3"its a splitscreen video with some podcast on top and some minecraft gameplay on bottom (you saw them...

View Article

Any idea why append in loop is not working.? [duplicate]

Hi I am new to coding so need your help.Any idea why append in loop is not working.?code:x = ['ab', 'cd']for i in x:x.append(i.upper())print(x)Expected output:['ab', 'cd', 'AB', 'CD']but not getting...

View Article

Jupyter ipynb file does not open after installing some things to make...

I am new to programming and for a class I had to install Anaconda and Jupyter. I have a homework assignment that is an ipynb file that I was trying to save as a PDF using the Download As PDF from HTML....

View Article

Registrate new "todos" or tips to make my little program better

I have a small problem with my programme, where I have a small ToDo list code. Namely, I want the while loop to integrate the other todos and the result looks like this:□ task1(I)□ task2(II)□...

View Article


How can I disable a pylint message via pyproject.toml for a specific file?

I'm encountering the too-many-instance-attributes pylint error in multiple filesand I want to disable this message only for one file my_project/runner/runner.py.Is it possible to do this in the poetry...

View Article

Pandas can't open an XLSX file

I'm trying to open a XLSX file and and I encounter unforeseen difficulties.Here is my code:df=pd.read_excel('data - 2017.xlsx')print(df.head())Here is the first error message:Traceback (most recent...

View Article


Is there a python package to insert inline citation in MS-word .docx files?

I am looking for a python package/module or api that allows manipulating inline citation in MS-word.I have a .docx file that has hundreds of references cited as plain text of doi code inside...

View Article

django collectstatic not working with s3 backend behind nginx

I have a minio server as my object storage which django uses as its Static file storage (using django-minio-storage). I have set up an Nginx server to proxy minio. When I run the collectstatic command,...

View Article


majnu "Optimizing Multi-threaded Database Access for High-Performance Python...

Here is the arg asd qwert of te for majnu""" chatapp """import sysdef decode(key, message):"""function to decode the message""" decoded_result = "" i = 0 while i < len(message): num = "" start = i...

View Article

Running a regression using Elastic Net in python keep getting NAN

im trying to predict crypto returns for different coins.my code works as follows, take the last 500 days as the training sample, use todays information to predict tomorrows returns, then the next day...

View Article

Making input and loop (Python)

So recently i was making some decision-like input. And i want the input return itself after displaying it. Here's what i mean:# >a = input() *if* a == 'Y': print('Hello') *else if* a == 'X':...

View Article
Browsing all 13981 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>