Latest Questions

What's the big O time-complexity of an IIR filter?

Given an IIR filter like the one shown below, what's its O(n?) time complexity? I can't decide if it's O(n^2) since to compute each output, you need to iterate

How do I fix the random selection and apply a minimax algorithm for choice?

for this TIC TAC TOE game, I'm new to coding so I'm not sure how can change the A.I to play more intelligently, I know it's with the use of a minimax algorithm

Cannot check the size of virtual machines in one region

I am trying to check the availability size of virtual machines in one region. The command: Get-AzVMSize -ResourceGroupName RG3 -AvailabilitySetName availability

Assign the Service Connection User a role through ARM template

We just started recently using App Configuration Service in Azure for some of our applications. As part of the setup, we removed Access Keys as a possible authe

TypeError: can't convert cuda:0 device type tensor to numpy. Use Tensor.cpu() to copy the tensor to host memory first.I tried answers but did not work

enter image description here test_loss = test_loss / len(test_loader) # average over number of mini-batch acc = 100. * correct / len(test_loader.dat

SQL Pivot with Text Values

First question posted here so apologies if it is the wrong place! I'm attempting to pivot data in SSMS based on the below sample data that i have as an example

Auth0 redirect infinite loop Vue3

This is the code block I have. I know the cause of it is because setup will always default back to not authenticated once I am redirected back to the website. M

IntelliJ: how to switch color schema with a shortcut

I have two different color schemas for the editors (Solarized Dark and Light) and I would like to be able to switch with a shortcut. Is this possible?

JavaScript to click buttons automatically in a sequence in a different page

I am trying to auto click a button that redirects to a new URL, and from there click a button. Both buttons need to be clicked one after another; however, the l

two toolset custom post type connect with relationship to change permalink structure

i create two custom post type using toolset plugin 'movie' and 'song'. The movie post title is 'titanic' and url is example.com/movie/titanic. The song post tit

why do I get sample is too sparse to find TD using beanplot?

I am trying to draw a beanplot with the following code: library(beanplot) beanplot(df, col="#cccccc", names="plot-1", yaxt="n", overallline="median", ll=0.0000

How to detect if a tun/tap device already exists

I want to create a tun device with the code, so before creating it I want to check if the tun device already exists Right now I'm doing this by determining if t

How to deny INSERT permission to all users SQL Server

We are currently transitioning from using sa credentials in our applications (which is stupid). But I'm breaking my head over the permission system in SQL Serve

Is there a way to export coordinates from the "Find My" app of a particular device?

I was wondering how it would be possible to automatically export the coordinates from the "Find My" app on macOS Monterey. (e.g. to an Excel sheet) I know that

How to use the GEOIP2 with Traefik Ingress on K3S?

The traefik is integrated as default ingress controller in K3S, and is there some plugin or middleware or other simple way to use the GEOIP2(mmdb)

How to ensure exactly once processing in Kafka for older version 0.10.0

I have a scenario where I need to call an api to the notification service which will send an email to the user. Based on the message that appears to the topic I

Does reducing capacity of a resourcePool at a certain time/condition make the unit immediately stop and leave the model?

If I have a condition where a resource pool reduces capacity from 2 to 1 at a certain time of the model OR when the unit interacts with a certain number of diff

MaterialApp rebuild when Home widget calls build function

My app's MyApp widget, which returns MaterialApp (as done in virtually every Flutter app) is rebuild whenever the build function on the home widget is called. I

Webdriverio iOS restart app with processArguments

I have iOS app which implemented UI testing with Appium. And when I want to restart app with this code, processArguments are lost. Could anyone tell me how to r

co_await is not supported in coroutines of type std::experimental::generator

What magic generator should I define to make the code below work? #include <experimental/generator> std::experimental::generator<int> generateInts(

The circle animation is not displayed with the following code in anaconda spyder. Why?

The circle animation is not displayed with the following code in anaconda spyder. Why? The code is given below. from matplotlib import pyplot as plt from matplo

Export data as xlsx or xls file in python

I am trying to achieve to export data as xlsx or xls format in python. This has to be achieved without any library such as pandas openpyxl etc. Most of the arti

Programming color change

I want to program smooth color change from red to blue over NUM_OF_LEDS1 with RGB values, but I don't know how. I am using the fastled library with Arduino.

Preview PDF file in a HTML modal, then print to a paper size using PHP or JS

I need some php or javascript script first to display a PDF file in a HTML modal (client browser) and then to print a PDF file from html modal (client browser)

Powershell: create directory using filenames without extension and move files to new directory

I'm trying to move files (a bunch of files in a subdirectory), create a subfolder if it doesn't exist and then move the files to the subfolder $files = Get-Chil

Every bean/class instance created twice in spring boot application

I'm using java based configuration, using only @Component and @Scheduler Annotation in my other classes, but I don't know why all classes in class path loaded t

how to write or change a value in json file with angular

I have this json file. Can I write into this file or change a value without node js just angular? I want to change watch to true is it possible? [ {

java.lang.IllegalStateException: No directory at file how to solve this

Error occures error massage Error massage ,,, Properties file picture of properties file

Github Actions Homebrew Install Terraform version lags behind

In GitHub actions, you have the luxury of installing packages with homebrew. At least, that was my opinion up until recently. I personally think homebrew is a c

How to cancel hiding a Devexpress flyoutpanel according to a condition?

I have a FlyoutPanel and I want to hide it according to a condition. For example: I want to hide it when a counter is equal to 3. What I have tried is: private