StackOverflow.com

VN:F [1.9.22_1171]
Rating: 9.4/10 (10 votes cast)

Random snippets of all sorts of code, mixed with a selection of help and advice.

Azure SQL Database DTU tier change billed for more than 24 hours — how is this calculated?

10 July 2025 @ 12:13 pm

I'm currently reviewing billing details for an Azure SQL Database configured with the DTU-based pricing model. On several days, I noticed the total billed hours exceeded 24h, even though the database was running continuously. For example, on April 1st, a single database with multiple tier changes (S9 → S7 → S4) was billed for a total of 26.02 hours in a single calendar day. Here's a simplified breakdown: Tier Cost (€) Price/hour (€) Estimated billed hours S9 35.85 2.7554 13.01 h S7 5.98 1.3777 4.34 h S4 2.61 0.3445 7.59 h Total = 24.94 h At first, I expected Azure to apply hourly rounding per tier like it does for VMs, where any activity (even 5 minutes) results in a full hour charged. But it seems Azure SQL uses fractional hour billing for DTU tier switches, and does not round to the nearest hour. This behavior isn't clearly documented in Microsoft's official pricing pages. My questions: Is this behavior offici

JPEG XS encoder fails to process 4:2:0 10-bit YUV with lossless compression

10 July 2025 @ 12:12 pm

I am trying to losslessly compress a raw YUV file using a JPEG XS encoder, but I'm encountering two main problems. My Environment: Encoder: JPEG XS test model (XSM) version 2.0.2-ED2 Input File: Raw YUV video frame Chroma Subsampling: 4:2:0 Bit Depth: 10-bit (Little Endian) Resolution: 832x480 (I have also tested with smaller resolutions like 64x64 with the same result) The Problems: Incorrect Profile Forcing: The encoder seems to ignore the 4:2:0 nature of my input. The only way I can get it to produce any output is by specifying a 4:2:2 profile, like main422.10. This is fundamentally incorrect for my source file. Lossless Encoding Failure: My primary requirement is lossless compression. When I add the parameter for lossless encoding (rl=1), the process fails immediately. The error is Unable to allocate encoding context. This happens regardless of the image resolution. My Question: How can I correctly encode my 4:2:0 10-bit YUV file in a lossless format?

Pair the iOS Application with Mac Application using WiFi pairing its not working when using Bonjour Services

10 July 2025 @ 12:11 pm

I'm working on an Objective-C project that uses the MYNetwork framework for connection and pairing. https://github.com/snej/MYNetwork?tab=readme-ov-file The framework works fine on iOS 16 with Xcode 14, and pairing functions as expected in that environment. However, when I run the same project on the latest iOS version and Xcode, the pairing no longer works. There are no crashes, but the expected connection and Bonjour service behavior isn't happening. Can someone please help me identify what might be causing the issue on the newer OS/Xcode versions and how to fix it? Thanks in advance!

Set color scheme for each chart in column layout individually

10 July 2025 @ 12:11 pm

Consider the following example of a bar plot in horizontal layout. In each chart the y and color channels both encode column "y" of df. import altair as alt import numpy as np import polars as pl N = 20 df = pl.DataFrame({ 'x': np.repeat(range(N), 2), 'y': np.random.randint(0, 100, 2*N), 'class': np.tile(["A", "B"], N) }) alt.Chart(df).mark_bar().encode( x='x', y='y', column='class', color=alt.Color('y', scale=alt.Scale(scheme='greens')) ) How do I set the color scheme individually for each chart? Spltting the whole thing in two seperate charts does not work: a1 = (alt.Chart(df.filter(pl.col('class')=="A")) .mark_bar() .encode(x='x', y='y', color=alt.Color('y', scale=alt.Scale(scheme="greens")))) a2 = (alt.Chart(df.filter(pl.col('class')=="B")) .mark_bar() .encode(x='x', y='y', color=alt.Color(

Building flutter app with local engine build failed

10 July 2025 @ 12:09 pm

Execution failed for task ':app:checkReleaseAarMetadata'. Could not resolve all files for configuration ':app:releaseRuntimeClasspath'. Could not resolve io.flutter:arm64_v8a_release:+. Required by: project :app > Failed to list versions for io.flutter:arm64_v8a_release. > Unable to load Maven meta-data from https://dl.google.com/dl/android/maven2/io/flutter/arm64_v8a_release/maven-metadata.xml. > Could not GET 'https://dl.google.com/dl/android/maven2/io/flutter/arm64_v8a_release/maven-metadata.xml'. > Connect to dl.google.com:443 [dl.google.com/114.250.65.33] failed: Connect timed out I want to use my local built engine(with flutter sdk changed),I configured the mirror source in gradle, but it seems that it will eventually go to Google source or even jcenter. Where is the source reposit

Why is "with torch.cuda.stream()" not asynchronous?

10 July 2025 @ 12:00 pm

Cause I'm trying to achieve the overlap between the forward and backward passes of two model chunks in dualpipe. I plan to simply implement it using torch.cuda.stream first, as follows: def overlapped_forward_backward( module0: torch.nn.Module, inputs0: List[torch.Tensor], labels0: Optional[List[torch.Tensor]], loss_masks0: Optional[List[torch.Tensor]], loss1: Optional[torch.Tensor], outputs1: Optional[List[torch.Tensor]], output_grads1: Optional[List[torch.Tensor]], forward_step_func: Callable, is_last_stage0: bool, ) -> tuple[torch.Tensor, Optional[torch.Tensor]]: """ You should implement custom forward-backward overlap strategy. The code below is just an example. """ device = inputs0[0].device if not hasattr(overlapped_forward_backward, 'backward_streams'): overlapped_forward_backward.backward_streams = {} if device not in overlapped_forward_backward.ba

Sending emails from the Linux terminal while preserving the fact of sending, but without attachments

10 July 2025 @ 11:59 am

I need to send a letter from Linux terminal to the recipient's mailing address from the terminal. I want the fact of sending the letter, its title and its text to be saved in the sent section of my mailbox (the mailbox is administered by another company). The attachments that I will be sending take up quite a lot of space and I would like them not to be saved on the mail server. It would be great if I didn't have to click to send them as in the script below. Here is my previous solution, this method saves the attachments and forces me to click. thunderbird -compose to="${mails}" ,subject="${sub}" ,body="${text}" ,attachment="'${attach},${letter}'";

Bot translator in discord

10 July 2025 @ 11:56 am

I was trying to create a bot in discord that would perform the function of double translation in voice channels, this code is written through the deepseek neural network. I ran into such a problem that when downloading discord.py [voice] discord is not installed.sinks, without which, as I understand it, work is not possible, I cannot find this library separately. And if possible, write down what can be added, corrected, and how best to do it. import os import asyncio import discord from discord.ext import commands from discord.sinks import MP3Sink # Импорт из стандартной библиотеки from transformers import ( WhisperForConditionalGeneration, WhisperProcessor, AutoTokenizer, AutoModelForSeq2SeqLM ) from gtts import gTTS from io import BytesIO import logging # Настройка логирования logging.basicConfig(level=logging.INFO) logger = logging.getLogger(__name__) # Конфигурация (замените н

How to stop reload page in browser to generate random data in Axios and Express?

10 July 2025 @ 11:55 am

I have a button in the EJS file that would generate random data from a selected API link. The problem is that whenever I press refresh the page to return to the original state (not generating anything), it just keeps generating random data despite not being pressed by the button. So far, I haven't tried anything because there was no error, so I don't know what I did wrong. How to stop refresh page in the browser to generate random data? Here is my index.js file code: import express from "express"; import axios from "axios"; const app = express(); app.set("view engine", "ejs"); const port = 3000; const API_URL = "http://www.thecocktaildb.com/api/json/v1/1/random.php"; // const apiKey = "1"; app.use(express.static("public")); app.get("/", (req, res) => { res.render("index.ejs"); }) app.post("/", async (req, res) => { try{ const result = a

DEG analysis in R

10 July 2025 @ 11:54 am

I want to download the GSE203206 Alzheimer's dataset from the GEO website using the R GEOquery package. I want to perform PCA on the raw count with ggplot. Then, I want to perform normalization and DEG analysis with the DESeq2 package. Meanwhile, I want to control rows with 0 gene count and NA values ​​and rows with very low gene counts, delete rows with 0 and NA values, and use the group_by function in tidyverse to filtrate rows with low counts. I tried this code but I could not get a clear output, could you help me ? if (!requireNamespace("BiocManager", quietly = TRUE)) install.packages("BiocManager") BiocManager::install(c("GEOquery", "DESeq2", "AnnotationDbi", "org.Hs.eg.db"), ask = FALSE) install.packages(c("tidyverse", "ggplot2", "pheatmap", "data.table"), dependencies = TRUE) library(GEOquery) library(DESeq2) library(tidyverse) library(ggplot2) lib

wolframalpha.com

VN:F [1.9.22_1171]
Rating: 9.4/10 (5 votes cast)

Access to the world’s facts and data and calculates answers across a range of topics, including science, nutrition, history, geography, engineering, mathematics, linguistics, sports, finance, music…

Analyzing Semaglutide’s Biochemistry with Wolfram Language

22 May 2025 @ 2:01 pm

Semaglutide is the active ingredient in a couple of popular anti-obesity medications. It is a glucagon-like peptide-1 (GLP-1) receptor agonist that mimics the action of our naturally occurring GLP-1 hormone. Semaglutide is 94% similar in structure to our natural GLP-1 hormone, and it works similarly to lower blood glucose and regulate appetite.

Wolfram|Alpha, 이제 한국어로 사용하세요!

23 April 2025 @ 2:01 pm

Wolfram|Alpha를 이제 한국어로 편하게 사용하실 수 있습니다! 간체 중국어, 일본어, 스페인어, 영어에 이어 이번에 추가된 한국어 지원은 전 세계 누구나 체계적인 지식을 즉시 계산하고 활용할 수 있도록 돕는 Wolfram|Alpha의 비전을 한 단계 더 확장하는 중요한 이정표입니다. 앞으로도 더 많은 언어로 서비스를 확장해 나가며, 더 많은 사용자에게 지식의 힘을 제공할 수 있도록 노력하겠습니다.

Wolfram|Alpha 简体中文版, 现已上线

23 April 2025 @ 2:01 pm

我们很高兴地宣布,Wolfram|Alpha 简体中文版现已正式推出!这是继韩语、日语、西班牙语和英语之后,我们语言家族的又一重要成员,进一步实现了我们的长期愿景⸺让所有系统性知识变得即时可计算,并让全球每一个人都能轻松获取。

Wolfram|Alpha, Now in Simplified Chinese and Korean!

23 April 2025 @ 2:01 pm

We are excited to announce that Wolfram|Alpha is now available in simplified Chinese and Korean! This adds to our growing list of languages, including Japanese, Spanish and English, allowing us to continue to support our long-term goal of making all systematic knowledge immediately computable and accessible to everyone.

Diving into the Wolfram High School Summer Research Program

18 April 2025 @ 4:08 pm

As the Precollege Educational Programs Manager at Wolfram, I have the privilege of working with hundreds of bright, passionate students from middle school to college. In this post, we’ll be exploring the Wolfram High School Summer Research Program, Wolfram’s flagship program for younger students. I’ve been the Program Director since 2019, and it’s been a joy to expand and extend the Wolfram education ecosystem over that time. We have worked hard to create enrichment programs for talented students, and we now have a rich ecosystem of opportunities for students of all ages.

Wolfram Middle School Summer Camp: A Virtual Learning Experience

18 April 2025 @ 4:08 pm

This summer marks the fifth annual Wolfram Middle School Summer Camp. Students at the camp learn the basics of Wolfram Language and make connections with other young STEM enthusiasts from around the world. Our goal with this fully virtual camp is to offer an on-ramp into other Wolfram programs for girls and gender non-conforming students with diverse academic backgrounds.

Wolfram Education Programs for Middle School, High School and Beyond

18 April 2025 @ 4:08 pm

The precollege education team at Wolfram runs a wide range of programs and experiences for students from middle school and up. Many of our students start out with asynchronous online programs to get a feel for computational thinking and coding before moving on to our synchronous online programs or in-person programs.

What’s Up with Daylight Saving Time? A Brief History and Analysis with Wolfram Language

5 March 2025 @ 5:12 pm

In the next few days, most people in the United States, Canada, Cuba, Haiti and some parts of Mexico will be transitioning from “standard” (or winter) time to “daylight” (or summer) time. This semiannual tradition has been the source of desynchronized alarm clocks, missed appointments and headaches for parents trying to get kids to bed at the right time since 1908, but why exactly do we fiddle with the clocks two times a year?

A Whole New Ball Game: Game Theory in Wolfram Language 14.2

25 February 2025 @ 6:17 pm

Do you want to make optimal decisions against competition? Do you want to analyze competitive contexts and predict outcomes of competitive events? Do you need to elaborate strategies and plans against adversity and test the effectiveness of those strategies? Or are you simply an undergraduate student struggling to cope with a required course on game […]

Itchy Boots

VN:F [1.9.22_1171]
Rating: 9.0/10 (5 votes cast)

Motorcycle adventures from a single perspective.

Red Letter Media

VN:F [1.9.22_1171]
Rating: 9.0/10 (4 votes cast)

Movie reviews from VCR repair men.
Continue reading

44Teeth

VN:F [1.9.22_1171]
Rating: 9.0/10 (3 votes cast)

Motorcycle vblog and chat with challenges.
Continue reading

WHF Entertainment

VN:F [1.9.22_1171]
Rating: 9.0/10 (2 votes cast)

A look into the crazy world with Whats her face.

joeybtoonz

VN:F [1.9.22_1171]
Rating: 9.0/10 (1 vote cast)

One man’s look at clown world (tiktok/narcissistic culture).

Fashion and #IDIOCRACY 3

19 June 2025 @ 11:11 pm

Wackjobs and #PROTESTS 4

12 June 2025 @ 7:21 pm

Why Is She Like This!? 5

25 May 2025 @ 4:19 pm

This Is Why I Stay Home 14

4 May 2025 @ 1:52 pm

TikTok and #IDIOCRACY 17

19 April 2025 @ 2:40 pm

My Advice to Justin Bieber

7 April 2025 @ 2:49 pm

This Is Why I Stay Home 13

2 April 2025 @ 5:51 pm

kubuntu.org

VN:F [1.9.22_1171]
Rating: 9.0/10 (1 vote cast)

Kubuntu is a free, complete, and open-source alternative to Microsoft Windows and Mac OS X which contains everything you need to work, play, or share.

Plasma 6.4 Beta1 available for testing

18 May 2025 @ 8:25 am

Are you using Kubuntu 25.04 Plucky Puffin, our current stable release? Or are you already running our development builds of the upcoming 25.10 (Questing Quokka)? We currently have Plasma 6.3.90 (Plasma 6.4 Beta1) available in our Beta PPA for Kubuntu 25.04 and for the 25.10 development series. However this is...

Plasma 6.3.5 update for Kubuntu 25.04 available via PPA

8 May 2025 @ 6:28 pm

We are pleased to announce that the Plasma 6.3.5 bugfix update is now available for Kubuntu 25.04 Plucky Puffin in our backports PPA. As usual with our PPAs, there is the caveat that the PPA may receive additional updates and new releases of KDE Plasma, Gear (Apps), and Frameworks, plus...

Kubuntu 25.04 Plucky Puffin released

17 April 2025 @ 4:18 pm

The Kubuntu Team is happy to announce that Kubuntu 25.04 has been released. Codenamed “Plucky Puffin”, Kubuntu 25.04 continues our tradition of giving you Friendly Computing by integrating the latest and greatest open source technologies into a high-quality, easy-to-use Linux distribution. The release features the latest KDE Plasma 6.3 desktop,...

Kubuntu Plucky Puffin (25.04) Beta released

27 March 2025 @ 6:30 pm

The beta of Kubuntu Plucky Puffin (to become 25.04 in April) has now been released, and is available for download. This milestone features images for Kubuntu and other Ubuntu flavours. Pre-releases of Kubuntu Plucky Puffin are not recommended for: Anyone needing a stable system Regular users who are not aware...

Kubuntu 24.10 Oracular Oriole Released

10 October 2024 @ 3:05 pm

The Kubuntu Team is happy to announce that Kubuntu 24.10 has been released, featuring the new and beautiful KDE Plasma 6.1 simple by default, powerful when needed. Codenamed “Oracular Oriole”, Kubuntu 24.10 continues our tradition of giving you Friendly Computing by integrating the latest and greatest open source technologies into...

Kubuntu Oracular Oriole (24.10) Beta released

21 September 2024 @ 10:38 pm

The beta of Kubuntu Oracular Oriole (to become 24.10 in October) has now been released, and is available for download. This milestone features images for Kubuntu and other Ubuntu flavours. Pre-releases of Kubuntu Mantic Minotaur are not recommended for: Anyone needing a stable system Regular users who are not aware...

Introducing the Enhanced KubuQA: Revolutionising ISO Testing Across Ubuntu Flavors

12 May 2024 @ 9:28 pm

The Kubuntu Team are thrilled to announce significant updates to KubuQA, our streamlined ISO testing tool that has now expanded its capabilities beyond Kubuntu to support Ubuntu and all its other flavors. With these enhancements, KubuQA becomes a versatile resource that ensures a smoother, more intuitive testing process for upcoming...

Kubuntu 24.04 LTS Noble Numbat Released

25 April 2024 @ 4:16 pm

The Kubuntu Team is happy to announce that Kubuntu 24.04 has been released, featuring the ‘beautiful’ KDE Plasma 5.27 simple by default, powerful when needed. Codenamed “Noble Numbat”, Kubuntu 24.04 continues our tradition of giving you Friendly Computing by integrating the latest and greatest open source technologies into a high-quality,...

Kubuntu 24.04 Beta Released

12 April 2024 @ 6:33 pm

Join the Excitement: Test Kubuntu 24.04 Beta and Experience Innovation with KubuQA! We’re thrilled to announce the availability of the Kubuntu 24.04 Beta! This release is packed with new features and enhancements, and we’re inviting you, our valued community, to join us in fine-tuning this exciting new version. Whether you’re...

Celebrating Creativity: Announcing the Winners of the Kubuntu Contests!

9 April 2024 @ 8:38 pm

We are thrilled to announce the winners of the Kubuntu Brand Graphic Design contest and the Wallpaper Contest! These competitions brought out the best in creativity, innovation, and passion from the Kubuntu community, and we couldn’t be more pleased with the results. Kubuntu Brand Graphic Design Contest Winners The Kubuntu...

Ultra Harmonics

VN:F [1.9.22_1171]
Rating: 8.8/10 (4 votes cast)

Cool vibes and ultra Harmonics, instrumental in it’s finest.
Continue reading

The Late Brake Show

VN:F [1.9.22_1171]
Rating: 8.7/10 (3 votes cast)

Car caves, reviews and insights via Jonny Smith (that bloke from Fifth Gear).