Pages

Showing posts with label linux tools. Show all posts
Showing posts with label linux tools. Show all posts

Thursday, August 27, 2026

News : Darktable 5.6.1: Stability, GPU fixes and AI improvements for Fedora and other Linux distributions.

Darktable 5.6.1 was released on August 27, 2026, with a technical focus on improving stability, memory handling, and GPU compatibility specifically on Fedora and other Linux distributions that adopt cutting‑edge toolchains and graphics stacks.
Fedora users benefit from native Wayland support in the official AppImage, allowing Darktable to run directly on GNOME’s Wayland session without relying on XWayland, while still providing automatic fallback to X11 for systems with incomplete OpenCL or Vulkan implementations.
The update addresses AMD GPU issues encountered frequently on Fedora due to Mesa Rusticl, eliminating pixel corruption and reducing OpenCL buffer allocation failures that previously caused crashes in modules such as denoise, sharpen, and tone equalizer.
Darktable 5.6.1 improves the RAW processing pipeline by enhancing ONNX model handling, adding automatic retry for interrupted downloads, and ensuring full metadata preservation for AI‑generated images, including EXIF, geotags, ratings, and color labels.
The AI RAW denoise module now rejects Fujifilm Super CCD sensors explicitly, preventing incorrect processing results caused by unsupported training data and ensuring predictable behavior across Fedora’s diverse camera workflows.
Multiple stability issues in wavelet decomposition, path masks, and raster masks are resolved, addressing crash patterns that were more visible on Fedora due to its early adoption of GCC 14 and Clang 18, whose aggressive optimizations exposed subtle bugs in previous Darktable builds.
Export reliability is improved through corrections in JPEG 2000 YCbCr 4:2:0 decoding and PNG 16‑bit color handling, fixing inconsistencies triggered by Fedora’s up‑to‑date libpng and openjpeg libraries.
On macOS, Darktable 5.6.1 provides separate builds for x86_64 and ARM64, ensuring optimized performance on Apple Silicon devices through improved integration with Metal and OpenCL layers, although the primary technical impact of this release remains centered on Linux and Fedora.
The update reduces crash frequency on macOS when applying 3D LUTs or running AI modules, thanks to adjustments aligned with recent Apple Clang and SDK changes, maintaining parity with Fedora’s stability improvements.
Windows users receive a fix for AMD OpenCL devices that were previously disabled, restoring full GPU acceleration, but Fedora remains the distribution with the most significant improvements due to its modern graphics stack and rapid package updates.
Package distribution for Linux is updated through OBS, PPA, Flatpak, and Fedora’s community repositories, ensuring that Fedora users receive the latest Darktable 5.6.1 builds compiled against current system libraries and toolchains.

Tuesday, June 16, 2026

Fedora immutable : Immutable Linux distributions and their development by the Fedora team.

What Are Immutable Linux Versions?
  • Immutable Linux distributions are operating systems where the core system is read-only and cannot be modified directly by the user.
  • Examples include Fedora Silverblue (GNOME-based) and Fedora Kinoite (KDE Plasma-based) ...
  • The system is built from atomic images, similar to how mobile operating systems update.
  • Applications and development tools run in containers instead of modifying the base system.
Main Characteristics and Functionality
  • The base system is read-only, preventing accidental or harmful changes.
  • Updates are atomic: the entire system updates as one unit and can be rolled back instantly.
  • Applications are installed through Flatpak or container environments like Toolbox and Distrobox.
  • System integrity is preserved because the OS image remains consistent across reboots.
Security Features
  • The read-only system reduces the attack surface by preventing unauthorized modifications.
  • Atomic updates ensure that incomplete or corrupted updates do not break the system.
  • Containerized applications isolate software from the core system, improving security.
  • Rollback capability allows users to revert to a previous working state after a failed update.
Hardware and Software Limitations
  • Some proprietary drivers may require manual workarounds because the base system cannot be modified directly.
  • Legacy hardware may not be fully supported due to the modern design of immutable systems.
  • Traditional package managers like dnf or apt cannot install software into the base system.
  • Advanced system customization is limited because configuration files are protected.
Advantages
  • High stability due to the read-only system design.
  • Fast and reliable updates with rollback support.
  • Improved security through isolation and immutability.
  • Ideal for developers using container-based workflows.
  • Consistent system state across reboots and installations.
Disadvantages
  • Less flexibility for users who want to modify system internals.
  • Some software may not work if it requires direct system-level installation.
  • Learning curve for users unfamiliar with Flatpak or container tools.
  • Not ideal for niche hardware requiring custom drivers.
Immutable Fedora Linux Versions: Silverblue and Kinoite
What Are Immutable Linux Versions?
  • Immutable Linux distributions are operating systems where the core system is read-only and cannot be modified directly by the user.
  • Examples include Fedora Silverblue (GNOME-based) and Fedora Kinoite (KDE Plasma-based).
  • The system is built from atomic images, similar to how mobile operating systems update.
  • Applications and development tools run in containers instead of modifying the base system.
Main Characteristics and Functionality
  • The base system is read-only, preventing accidental or harmful changes.
  • Updates are atomic: the entire system updates as one unit and can be rolled back instantly.
  • Applications are installed through Flatpak or container environments like Toolbox and Distrobox.
  • System integrity is preserved because the OS image remains consistent across reboots.
Security Features
  • The read-only system reduces the attack surface by preventing unauthorized modifications.
  • Atomic updates ensure that incomplete or corrupted updates do not break the system.
  • Containerized applications isolate software from the core system, improving security.
  • Rollback capability allows users to revert to a previous working state after a failed update.
Hardware and Software Limitations
  • Some proprietary drivers may require manual workarounds because the base system cannot be modified directly.
  • Legacy hardware may not be fully supported due to the modern design of immutable systems.
  • Traditional package managers like dnf or apt cannot install software into the base system.
  • Advanced system customization is limited because configuration files are protected.
Advantages
  • High stability due to the read-only system design.
  • Fast and reliable updates with rollback support.
  • Improved security through isolation and immutability.
  • Ideal for developers using container-based workflows.
  • Consistent system state across reboots and installations.
Disadvantages
  • Less flexibility for users who want to modify system internals.
  • Some software may not work if it requires direct system-level installation.
  • Learning curve for users unfamiliar with Flatpak or container tools.
  • Not ideal for niche hardware requiring custom drivers.
Why Fedora Atomic Desktop Versions Lag Behind Workstation
Fedora Atomic Desktops (immutable editions - 40) do not follow the same release pace as Fedora Workstation 44 – April 2026. While Workstation receives a new version every six months, the immutable editions often remain several versions behind. This happens because immutable systems require additional testing, image validation, and stability checks before release.
Main Reasons for Version Differences
  • Immutable systems use rpm-ostree, which requires more complex testing than traditional package-based systems.
  • Atomic updates and rollback functionality must be verified for every release.
  • Desktop environments must be adapted to work correctly in a read-only system.
  • The Fedora Atomic team is smaller and focuses on stability over rapid version progression.
  • New immutable editions (Onyx, Aurora, Sericea) increased development workload.
Current Immutable Editions
  • Fedora Silverblue (immutable, GNOME)
  • Fedora Kinoite (immutable, KDE Plasma)
  • Fedora Sericea (immutable, Sway)
  • Fedora Onyx (immutable, Budgie)
  • Fedora Aurora (immutable, LXQt)
Release Timeline for Immutable Editions
  • Fedora releases occur twice per year: April and October.
  • Workstation versions advance regularly (e.g., Fedora 44 in 2026).
  • Immutable editions often remain at older versions (e.g., Silverblue 40) until stability is guaranteed.
  • Development for immutable editions happens first in Rawhide, then moves to a stable branch.
  • Version numbers for immutable editions may skip or delay compared to Workstation.
Development
  • Atomic Rawhide (future Fedora 41 Atomic)
  • Rawhide is the testing ground for all new immutable features.
  • New images are built and validated before becoming a stable release.
How Development Works for Immutable Fedora
  • All new changes are introduced in Rawhide, the rolling development branch.
  • The system is built as an OSTree image instead of traditional packages.
  • Each image must pass atomic update and rollback validation.
  • Flatpak integration and container tools (Toolbox, Distrobox) must be tested for compatibility.
  • Only after stability is confirmed, the immutable edition receives a new version number.
Why Immutable Editions Prioritize Stability
  • Atomic systems must guarantee that updates never break the OS.
  • Rollback must work flawlessly for every release.
  • Desktop environments must behave correctly in a read-only environment.
  • Consistency and reliability are more important than rapid version progression.

Monday, June 8, 2026

News : HandBrake 1.11.2 added WebM MIME type to the list of the supported formats.

HandBrake 1.11.2 has been released with WebM MIME type to the list of supported formats on Linux systems, improve the Core Audio AAC encoder 7.1 channel layout, improve handling of unsupported presets on macOS and Windows systems, and improve queue low space pause behaviour on Windows systems.

Sunday, June 7, 2026

News : Release v0.15.1 for Black Box .

Black Box is a native terminal emulator for GNOME that offers superb theming options.
With Black Box you can:
  • Set colors schemes and integrate them with the rest of the window
  • Customize font and size
  • Customize keyboard shortcuts
  • Render Sixel escape sequences
  • Fully hide the window headerbar
  • Quickly open links and files by ctrl+clicking file paths and URLs
  • Easily paste file paths by dragging them into the window

Tuesday, June 2, 2026

Fedora 44 : the Zert plugin manager.

Zert is a pure-Zsh plugin manager built around a simple idea: your plugins should be declared directly in your .zshrc, pinned to exact commits, and reproducible on any machine just like npm does for Node projects.
This project can be found on this GitHub repo.
Let's see some commands:
zert zert                           # zert manages itself
zert use ohmyzsh                     # enable Oh-My-Zsh compatibility
zert ohmyzsh lib/clipboard           # OMZ library
zert use prezto                      # enable Prezto compatibility
zert prezto modules/utility          # Prezto module
zert zsh-users/zsh-autosuggestions   # GitHub shorthand
zert https://github.com/user/repo    # full URL
zert user/repo --branch dev          # track a branch
zert /home/me/my-plugin              # local plugin

zert user/plugin --pin abc123        # pin to commit
zert user/plugin --branch dev         # track branch
zert user/plugin --no-alias           # skip aliases
zert user/plugin --no-completion      # skip completions
zert user/plugin --only-completion    # completions only

zert list      # show installed plugins
zert update    # update all plugins
zert prune     # remove unused plugins

Friday, April 10, 2026

Fedora 44 : testing Django 6.0.4 .

Today I used Fedora 44 beta 12 server on VirtualBox, and I wanted to test how Python works with Django on this Linux distribution. In the Fedora distribution, I have Python version 3.14.3 and Django version 6.0.4. I created a basic project with multiple pages, CSS, JavaScript, and an admin interface. It seems that Django is functional, and the result is very good for a basic project.:

Wednesday, April 8, 2026

Fedora 44 : Fedora 44 Server with budgie ...

The old laptop on which I was running Fedora broke down. That didn't stop me from testing Fedora Server version 44 beta 12 with the Budgie environment in VirtualBox, and I also made a beginner tutorial video that I share on my YouTube channel - Catalin George Festila.
See this video:

Wednesday, January 15, 2025

Fedora 41 : evtest basic tool for linux devices.

The evtest is c - Input device event monitor and query tool.
root@fedora:/home/mythcat# dnf5 install evtest
Updating and loading repositories:
Repositories loaded.
Package                                           Arch         Version                                           Repository                      Size
Installing:
 evtest                                           x86_64       1.35-8.fc41                                       fedora                      63.0 KiB

Transaction Summary:
 Installing:         1 package

Total size of inbound packages is 30 KiB. Need to download 30 KiB.
After this operation, 63 KiB extra will be used (install 63 KiB, remove 0 B).
...
root@fedora:/home/mythcat# evtest
No device specified, trying to scan all of /dev/input/event*
Available devices:
/dev/input/event0:	Sleep Button
/dev/input/event1:	Lid Switch
/dev/input/event10:	HDA Intel Line
/dev/input/event11:	HDA Intel Headphone
/dev/input/event12:	PixArt USB Optical Mouse
/dev/input/event2:	Power Button
/dev/input/event3:	AT Translated Set 2 keyboard
/dev/input/event4:	SynPS/2 Synaptics TouchPad
/dev/input/event5:	Video Bus
/dev/input/event6:	ST LIS3LV02DL Accelerometer
/dev/input/event7:	Quickstart Button 1
/dev/input/event8:	HP WMI hotkeys
/dev/input/event9:	HDA Intel Mic
Select the device event number [0-12]:

Sunday, January 5, 2025

Fedora 41 : the pref tool under Fedora.

Today I tested the perf tool in Fedora 41 and it is a bit difficult to use. I documented myself and found some information on the web and in the online linux community. Here is what I thought was worth remembering and what I tested.
The pref tool can't run anyway:
mythcat@fedora:~/PythonProjects$ perf record -e cache-misses,page-faults,minor-faults,major-faults,cpu-migrations,L1-dcache-load-misses,L1-dcache-store-misses,L1-icache-load-misses,LLC-load-misses,LLC-store-misses,dTLB-load-misses,dTLB-store-misses,iTLB-load-misses
Error:
Access to performance monitoring and observability operations is limited.
Enforced MAC policy settings (SELinux) can limit access to performance
monitoring and observability operations. Inspect system audit records for
more perf_event access control information and adjusting the policy.
Consider adjusting /proc/sys/kernel/perf_event_paranoid setting to open
access to performance monitoring and observability operations for processes
without CAP_PERFMON, CAP_SYS_PTRACE or CAP_SYS_ADMIN Linux capability.
More information can be found at 'Perf events and tool security' document:
https://www.kernel.org/doc/html/latest/admin-guide/perf-security.html
perf_event_paranoid setting is 2:
  -1: Allow use of (almost) all events by all users
      Ignore mlock limit after perf_event_mlock_kb without CAP_IPC_LOCK
>= 0: Disallow raw and ftrace function tracepoint access
>= 1: Disallow CPU event access
>= 2: Disallow kernel profiling
To make the adjusted perf_event_paranoid setting permanent preserve ...
I used with sudo , wait and Ctrl + C to stop:
mythcat@fedora:~/PythonProjects$ sudo perf record -e cache-misses,page-faults,minor-faults,major-faults,cpu-migrations,L1-dcache-load-misses,L1-dcache-store-misses,L1-icache-load-misses,LLC-load-misses,LLC-store-misses,dTLB-load-misses,dTLB-store-misses,iTLB-load-misses ...
To get the accurate number of events count then number of results:
mythcat@fedora:~/PythonProjects$ perf report -D -i perf.data | grep RECORD_SAMPLE | wc -l
22461
I get my pref data and I saw all my system data with:
mythcat@fedora:~/PythonProjects$ sudo perf report -f -i perf.data 

Friday, January 3, 2025

Fedora 41 : NVim from sources or packages !

Today I tried the nvim and saw this big issue:
root@fedora:/home/mythcat# dnf5 install neovim
...
Package                     Arch     Version                     Repository          Size
Installing:
 neovim                     x86_64   0.10.2-1.fc41               fedora          29.1 MiB
...
Installing weak dependencies:
 nodejs                     x86_64   1:22.11.0-3.fc41            updates        148.5 KiB
 nodejs-docs                noarch   1:22.11.0-3.fc41            updates         91.9 MiB
 nodejs-full-i18n           x86_64   1:22.11.0-3.fc41            updates         29.3 MiB
 nodejs-npm                 x86_64   1:10.9.0-1.22.11.0.3.fc41   updates          9.4 MiB
 ripgrep                    x86_64   14.1.1-1.fc41               updates          4.7 MiB
 tree-sitter-cli            x86_64   0.23.2-1.fc41               updates         12.4 MiB
 wl-clipboard               x86_64   2.2.1-3.fc41                fedora         140.9 KiB
 xsel                       x86_64   1.2.1-2.fc41                fedora          47.9 KiB
You can see comes with nodejs. I remove the nodejs and I tested nvim and works.
Using the source code works also well:
root@fedora:/home/mythcat# curl -LO https://github.com/neovim/neovim/releases/latest/download/nvim-linux64.tar.gz
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
100 11.4M  100 11.4M    0     0  5739k      0  0:00:02  0:00:02 --:--:-- 14.1M
root@fedora:/home/mythcat# sudo rm -rf /opt/nvim
root@fedora:/home/mythcat# sudo tar -C /opt -xzf nvim-linux64.tar.gz
root@fedora:/home/mythcat# export PATH="$PATH:/opt/nvim-linux64/bin"
root@fedora:/home/mythcat# nvim

Wednesday, January 1, 2025

Fedora 41 : Fix size of logical volume ... happy new year 2025!

Happy New Year 2025!
Today I come with this issue, is very old one ...
mythcat@fedora:~$ sudo vgs
[sudo] password for mythcat: 
  VG     #PV #LV #SN Attr   VSize  VFree 
  fedora   1   1   0 wz--n- 73.51g 58.51g
mythcat@fedora:~$ sudo lvresize -l +100%FREE --resizefs /dev/mapper/fedora-root
  Size of logical volume fedora/root changed from 15.00 GiB (3840 extents) to 73.51 GiB (18819 extents).
  File system xfs found on fedora/root mounted at /.
  Extending file system xfs to 73.51 GiB (78932606976 bytes) on fedora/root...
xfs_growfs /dev/fedora/root
meta-data=/dev/mapper/fedora-root isize=512    agcount=4, agsize=983040 blks
         =                       sectsz=512   attr=2, projid32bit=1
         =                       crc=1        finobt=1, sparse=1, rmapbt=1
         =                       reflink=1    bigtime=1 inobtcount=1 nrext64=1
data     =                       bsize=4096   blocks=3932160, imaxpct=25
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0, ftype=1
log      =internal log           bsize=4096   blocks=16384, version=2
         =                       sectsz=512   sunit=0 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0
data blocks changed from 3932160 to 19270656
xfs_growfs done
  Extended file system xfs on fedora/root.
  Logical volume fedora/root successfully resized.

Saturday, December 14, 2024

Fedora 41 : OpenCV example with PyQt6.

Today I tested another source code with opencv, numpy, PyQt6 python packages.
I install opencv python package with dnf5 tool:
root@localhost:/home/mythcat# dnf5 install  python3-opencv.x86_64
The source code let you to open, change a image and save using sliders and a reset option.
This is the source code:
import sys
import cv2
import numpy as np
from PyQt6.QtWidgets import QApplication, QMainWindow, QWidget, QVBoxLayout, QLabel, QSlider, QFileDialog, QPushButton, QHBoxLayout
from PyQt6.QtGui import QImage, QPixmap
from PyQt6.QtCore import Qt, pyqtSlot

class MainWindow(QMainWindow):
    def __init__(self):
        super().__init__()
        self.setWindowTitle("Real-Time Color Selection")
        self.setGeometry(100, 100, 1200, 800)

        # Create central widget and main layout
        central_widget = QWidget()
        self.setCentralWidget(central_widget)
        main_layout = QVBoxLayout(central_widget)

        # Create image label
        self.image_label = QLabel()
        main_layout.addWidget(self.image_label)

        # Initialize sliders
        self.lower_h = QSlider(Qt.Orientation.Horizontal)
        self.lower_s = QSlider(Qt.Orientation.Horizontal)
        self.lower_v = QSlider(Qt.Orientation.Horizontal)
        self.upper_h = QSlider(Qt.Orientation.Horizontal)
        self.upper_s = QSlider(Qt.Orientation.Horizontal)
        self.upper_v = QSlider(Qt.Orientation.Horizontal)

        # Set slider ranges
        for slider in [self.lower_h, self.upper_h]:
            slider.setRange(0, 179)
        for slider in [self.lower_s, self.lower_v, self.upper_s, self.upper_v]:
            slider.setRange(0, 255)

        # Set initial slider values
        self.lower_h.setValue(50)
        self.lower_s.setValue(100)
        self.lower_v.setValue(50)
        self.upper_h.setValue(130)
        self.upper_s.setValue(255)
        self.upper_v.setValue(255)

        # Connect sliders to update function
        self.lower_h.valueChanged.connect(self.update_hsv_range)
        self.lower_s.valueChanged.connect(self.update_hsv_range)
        self.lower_v.valueChanged.connect(self.update_hsv_range)
        self.upper_h.valueChanged.connect(self.update_hsv_range)
        self.upper_s.valueChanged.connect(self.update_hsv_range)
        self.upper_v.valueChanged.connect(self.update_hsv_range)

        # Create slider layouts with labels
        sliders_layout = QVBoxLayout()
        
        # Add slider pairs with labels
        slider_pairs = [
            ("Lower Hue", self.lower_h),
            ("Lower Saturation", self.lower_s),
            ("Lower Value", self.lower_v),
            ("Upper Hue", self.upper_h),
            ("Upper Saturation", self.upper_s),
            ("Upper Value", self.upper_v)
        ]

        for label_text, slider in slider_pairs:
            row_layout = QHBoxLayout()
            label = QLabel(label_text)
            label.setMinimumWidth(120)
            row_layout.addWidget(label)
            row_layout.addWidget(slider)
            sliders_layout.addLayout(row_layout)

        main_layout.addLayout(sliders_layout)

        # Add buttons
        button_layout = QHBoxLayout()
        
        self.reset_button = QPushButton("Reset Values")
        self.reset_button.clicked.connect(self.reset_values)
        button_layout.addWidget(self.reset_button)

        self.open_image_button = QPushButton("Open Image")
        self.open_image_button.clicked.connect(self.open_image)
        button_layout.addWidget(self.open_image_button)

        self.save_button = QPushButton("Save Image")
        self.save_button.clicked.connect(self.save_image)
        button_layout.addWidget(self.save_button)
        main_layout.addLayout(button_layout)

        # Process initial image
        self.process_image()

    def process_image(self):
        image_bgr = cv2.imread("image.png")
        if image_bgr is None:
            image_bgr = cv2.imread("default_image.png")
        
        self.image_bgr = image_bgr
        self.image_hsv = cv2.cvtColor(image_bgr, cv2.COLOR_BGR2HSV)

        # Create initial mask using current slider values
        lower_values = np.array([self.lower_h.value(), self.lower_s.value(), self.lower_v.value()])
        upper_values = np.array([self.upper_h.value(), self.upper_s.value(), self.upper_v.value()])
        
        mask_test = cv2.inRange(self.image_hsv, lower_values, upper_values)
        image_bgr_masked = cv2.bitwise_and(image_bgr, image_bgr, mask=mask_test)
        self.image_rgb = cv2.cvtColor(image_bgr_masked, cv2.COLOR_BGR2RGB)
        self.update_image()

    def update_image(self):
        height, width, channel = self.image_rgb.shape
        bytes_per_line = width * channel
        q_image = QImage(self.image_rgb.data, width, height, bytes_per_line, QImage.Format.Format_RGB888)
        pixmap = QPixmap.fromImage(q_image)
        self.image_label.setPixmap(pixmap.scaled(700, 500, Qt.AspectRatioMode.KeepAspectRatio))

    def update_hsv_range(self):
        lower_values = np.array([self.lower_h.value(), self.lower_s.value(), self.lower_v.value()])
        upper_values = np.array([self.upper_h.value(), self.upper_s.value(), self.upper_v.value()])
        mask_test = cv2.inRange(self.image_hsv, lower_values, upper_values)
        image_bgr_masked = cv2.bitwise_and(self.image_bgr, self.image_bgr, mask=mask_test)
        self.image_rgb = cv2.cvtColor(image_bgr_masked, cv2.COLOR_BGR2RGB)
        self.update_image()

    def reset_values(self):
        self.lower_h.setValue(50)
        self.lower_s.setValue(100)
        self.lower_v.setValue(50)
        self.upper_h.setValue(130)
        self.upper_s.setValue(255)
        self.upper_v.setValue(255)

    def open_image(self):
        filename, _ = QFileDialog.getOpenFileName(self, "Select Image File", "", "Image Files (*.png *.jpg *.jpeg)")
        if filename:
            self.image_bgr = cv2.imread(filename)
            if self.image_bgr is not None:
                self.image_hsv = cv2.cvtColor(self.image_bgr, cv2.COLOR_BGR2HSV)
                self.update_hsv_range()  # This will apply current filter and update display

    def save_image(self):
        filename, _ = QFileDialog.getSaveFileName(self, "Save Image", "", "PNG Files (*.png);;JPEG Files (*.jpg)")
        if filename:
            # Make sure filename has an extension
            if not filename.endswith(('.png', '.jpg', '.jpeg')):
                filename += '.png'
            # Convert and save
            output_image = cv2.cvtColor(self.image_rgb, cv2.COLOR_RGB2BGR)
            cv2.imwrite(filename, output_image)

if __name__ == "__main__":
    app = QApplication(sys.argv)
    window = MainWindow()
    window.show()
    sys.exit(app.exec())

Thursday, December 12, 2024

Fedora 41 : The cirq python package cannot be install - build errors

Today, I tried to use cirq python package on Fedora 41. This need the python version 3.12.
root@localhost:/home/mythcat# dnf install python3.12.x86_6c
I got some errors because ask me to install the rust:
root@localhost:/home/mythcat# curl https://sh.rustup.rs -sSf | sh
info: downloading installer

Welcome to Rust!

This will download and install the official compiler for the Rust
programming language, and its package manager, Cargo.

Rustup metadata and toolchains will be installed into the Rustup
home directory, located at:
...
Rust is installed now. Great!

To get started you may need to restart your current shell.
This would reload your PATH environment variable to include
Cargo's bin directory ($HOME/.cargo/bin).

To configure your current shell, you need to source
the corresponding env file under $HOME/.cargo.

This is usually done by running one of the following (note the leading DOT):
. "$HOME/.cargo/env"            # For sh/bash/zsh/ash/dash/pdksh
source "$HOME/.cargo/env.fish"  # For fish
These are the next steps I used:
root@localhost:/home/mythcat# pip install --upgrade pip
...
root@localhost:/home/mythcat# pip install maturin
...
root@localhost:/home/mythcat# pip install cirq
...
Collecting cirq
  Using cached cirq-1.4.1-py3-none-any.whl.metadata (7.4 kB)
...
        cargo:rerun-if-env-changed=PYO3_USE_ABI3_FORWARD_COMPATIBILITY
      
        --- stderr
        error: the configured Python interpreter version (3.13) is newer than PyO3's maximum supported version (3.12)
        = help: please check if an updated version of PyO3 is available. Current version: 0.20.3
        = help: set PYO3_USE_ABI3_FORWARD_COMPATIBILITY=1 to suppress this check and build anyway using the stable ABI
      💥 maturin failed
        Caused by: Failed to build a native library through cargo
        Caused by: Cargo build finished with "exit status: 101": `env -u CARGO PYO3_ENVIRONMENT_SIGNATURE="cpython-3.13-64bit" PYO3_PYTHON="/usr/bin/python3" PYTHON_SYS_EXECUTABLE="/usr/bin/python3" "cargo" "rustc" "--features" "pyo3/extension-module" "--message-format" "json-render-diagnostics" "--manifest-path" "/tmp/pip-install-v0zuc831/quil_ebc006157dbd433dbc0890811ee80748/quil-py/Cargo.toml" "--release" "--lib" "--crate-type" "cdylib"`
      Error: command ['maturin', 'pep517', 'build-wheel', '-i', '/usr/bin/python3', '--compatibility', 'off'] returned non-zero exit status 1
      [end of output]
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for quil
Failed to build quil
ERROR: ERROR: Failed to build installable wheels for some pyproject.toml based projects (quil)
Not working ...

Sunday, November 24, 2024

Fedora 41 : remove package lead to unexpected results.

Today I saw the mutter package from Fedora distro come with a new update.
I don't use this package, ... is a mess in my oppinion.
But I found this output when I tried to remove
root@localhost:/home/mythcat# dnf5 remove mutter 
Package                          Arch   Version                 Reposit      Size
Removing:
 mutter                          x86_64 47.1-3.fc41             updates  12.5 MiB
Removing dependent packages:
 gdm                             x86_64 1:47.0-8.fc41           updates   5.3 MiB
 gnome-shell                     x86_64 47.1-1.fc41             updates  13.8 MiB
Removing unused dependencies:
 accountsservice                 x86_64 23.13.9-5.fc41          fedora  379.5 KiB
 accountsservice-libs            x86_64 23.13.9-5.fc41          fedora  212.3 KiB
 bluez-obexd                     x86_64 5.79-1.fc41             updates 345.1 KiB
 bolt                            x86_64 0.9.8-3.fc41            fedora  503.3 KiB
 boost-thread                    x86_64 1.83.0-8.fc41           fedora  136.8 KiB
 color-filesystem                noarch 1-34.fc41               fedora  151.0   B
 colord                          x86_64 1.4.7-5.fc41            fedora    1.7 MiB
 colord-gtk4                     x86_64 0.3.1-2.fc41            fedora   35.6 KiB
 composefs-libs                  x86_64 1.0.6-1.fc41            fedora  166.3 KiB
 cups-pk-helper                  x86_64 0.2.7-8.fc41            fedora  379.0 KiB
 dbus-daemon                     x86_64 1:1.14.10-4.fc41        fedora  553.2 KiB
 evolution-data-server           x86_64 3.54.1-1.fc41           updates   8.8 MiB
 evolution-data-server-langpacks noarch 3.54.1-1.fc41           updates   8.8 MiB
 flatpak-libs                    x86_64 1.15.10-1.fc41          fedora    1.0 MiB
 ...
 
Is this ok [y/N]: N
 ... 
If I used this command the gdm and gnome-shell is gone:
root@localhost:/home/mythcat# dnf5 remove --noautoremove mutter 
Package                        Arch   Version                   Repository        Size
Removing:
 mutter                        x86_64 47.1-3.fc41               updates       12.5 MiB
Removing dependent packages:
 gdm                           x86_64 1:47.0-8.fc41             updates        5.3 MiB
 gnome-session-wayland-session x86_64 47.0.1-1.fc41             fedora        15.9 KiB
 gnome-shell                   x86_64 47.1-1.fc41               updates       13.8 MiB

Transaction Summary:
 Removing:           4 packages
 
Is this ok [y/N]: N
...
I tried with the --noautoremove, and --exclude args and not result:
root@localhost:/home/mythcat# dnf5 remove --noautoremove --exclude=gnome-shell,gdm mutter
Failed to resolve the transaction:
Problem: installed package gnome-shell-47.1-1.fc41.x86_64 requires libmutter-15.so.0()(64bit), but none of the providers can be installed
  - installed package gnome-shell-47.1-1.fc41.x86_64 requires libmutter-clutter-15.so.0()(64bit), but none of the providers can be installed
  - installed package gnome-shell-47.1-1.fc41.x86_64 requires libmutter-cogl-15.so.0()(64bit), but none of the providers can be installed
  - installed package gnome-shell-47.1-1.fc41.x86_64 requires libmutter-mtk-15.so.0()(64bit), but none of the providers can be installed
  - installed package gnome-shell-47.1-1.fc41.x86_64 requires mutter(x86-64) >= 47.0, but none of the providers can be installed
  - conflicting requests
  - problem with installed package
The solution is old rpm tool:
root@localhost:/home/mythcat# rpm -e --nodeps mutter 
root@localhost:/home/mythcat# dnf5 remove mutter
No packages to remove for argument: mutter

Nothing to do.

Wednesday, November 20, 2024

Fedora 41 : generated shapes with python !

Today I created this source code in python that generates eight random convex polygons. The idea was to create sprites for a 2D game: snowballs, boulders, or similar objects ... Obviously I also used Sonet 3.5 artificial intelligence. You can find the source code on the pagure account in fedora.
#!/usr/bin/env python3
"""
SVG Polygon Generator

This script generates multiple deformed polygonal shapes and saves them as separate SVG files.
Each polygon maintains convex properties while having controlled random deformations.

Features:
    - Generates 8 unique polygonal shapes
    - Controls deformation through radial and angular factors
    - Maintains convex properties
    - Exports each shape to a separate SVG file
    - Uses random colors for visual distinction

Usage:
    python generate_svgs.py

Output:
    Creates 8 SVG files named 'polygon_1.svg' through 'polygon_8.svg'
"""

from lxml import etree
import random
import math
from pathlib import Path


def create_svg_root():
    """Create and return a base SVG root element with standard attributes."""
    root = etree.Element("svg")
    root.set("width", "500")
    root.set("height", "500")
    root.set("xmlns", "http://www.w3.org/2000/svg")
    return root


def calculate_points(center_x: float, center_y: float, radius: float, 
                    num_sides: int, deform_factor: float) -> list:
    """
    Calculate polygon points with controlled deformation.

    Args:
        center_x: X coordinate of polygon center
        center_y: Y coordinate of polygon center
        radius: Base radius of the polygon
        num_sides: Number of polygon sides
        deform_factor: Maximum allowed deformation factor

    Returns:
        List of tuples containing (x, y) coordinates
    """
    points = []
    angle_step = 2 * math.pi / num_sides
    
    for i in range(num_sides):
        angle = i * angle_step
        radial_deform = random.uniform(-deform_factor, deform_factor)
        angular_deform = random.uniform(-deform_factor/2, deform_factor/2)
        
        modified_angle = angle + angular_deform
        modified_radius = radius * (1 + radial_deform)
        
        x = center_x + modified_radius * math.cos(modified_angle)
        y = center_y + modified_radius * math.sin(modified_angle)
        points.append((x, y))
    
    return points


def generate_deformed_shapes():
    """Generate multiple deformed polygons and save them to separate SVG files."""
    # Base parameters
    num_sides = 8
    center_x = 250
    center_y = 250
    base_radius = 150
    max_deformation = 0.15
    output_dir = Path("generated_polygons")
    
    # Create output directory if it doesn't exist
    output_dir.mkdir(exist_ok=True)

    for i in range(8):
        root = create_svg_root()
        points = calculate_points(center_x, center_y, base_radius, 
                                num_sides, max_deformation)
        
        path = etree.SubElement(root, "path")
        path_data = f"M {points[0][0]} {points[0][1]}"
        path_data += "".join(f" L {p[0]} {p[1]}" for p in points[1:])
        path_data += " Z"
        
        path.set("d", path_data)
        path.set("fill", "none")
        path.set("stroke", f"#{random.randint(0, 16777215):06X}")
        path.set("stroke-width", "2")
        path.set("opacity", "0.7")

        # Save individual SVG file
        output_file = output_dir / f"polygon_{i+1}.svg"
        tree = etree.ElementTree(root)
        tree.write(str(output_file), pretty_print=True, 
                  xml_declaration=True, encoding='utf-8')
    
    print(f"Generated {num_sides} polygons in {output_dir}")

if __name__ == "__main__":
    generate_deformed_shapes()

Saturday, November 16, 2024

Fedora 41 : Bookworm - open-source eBook reader !

Bookworm is an open-source eBook reader with an easy and simple layout supporting different file formats like epub, pdf, mobi, cbr and cbz. See the official webpage.
root@localhost:/home/mythcat# dnf5 search bookworm
Updating and loading repositories:
Repositories loaded.
Matched fields: name (exact)
 bookworm.x86_64: Simple, focused eBook reader
root@localhost:/home/mythcat# dnf5 install bookworm.x86_64
Updating and loading repositories:
Repositories loaded.
Package                 Arch   Version                      Repository      Size
Installing:
 bookworm               x86_64 1.1.3-0.13.20200414git.c7c36 fedora       3.6 MiB
Installing dependencies:
 granite                x86_64 6.2.0-9.fc41                 fedora     949.2 KiB
 javascriptcoregtk4.0   x86_64 2.46.3-1.fc41                updates     28.3 MiB
 webkit2gtk4.0          x86_64 2.46.3-1.fc41                updates     75.4 MiB

Transaction Summary:
 Installing:         4 packages
...
[6/6] Installing bookworm-0:1.1.3-0.13. 100% | 430.8 KiB/s |   3.7 MiB |  00m09s
Complete!ng trigger-install scriptlet: hicolor-icon-theme-0:0.17-19.fc41.noarch
The last step, search this on gnome environmet and you will find this application.

Thursday, October 17, 2024

Fedora 42 : Testing isoimagewriter.

Today I tested the isoimagewriter tool on Fedora 42 and works well:
[mythcat@fedora ~]$ sudo fdisk -l /dev/sdb
Disk /dev/sdb: 984 MiB, 1031798784 bytes, 2015232 sectors
Disk model: USB FLASH DRIVE 
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x00000000
[mythcat@fedora ~]$ isoimagewriter 
[mythcat@fedora ~]$ sudo file -s /dev/sdb
/dev/sdb: ISO 9660 CD-ROM filesystem data 'CorePure64' (bootable)
[mythcat@fedora ~]$ sudo qemu-system-x86_64 -cdrom /dev/sdb 
I used an linux iso image from CorePure64

Thursday, April 18, 2024

Fedora 41 : python and Federated Message Bus in Fedora Linux Distro.

Federated Message Bus is a library built on ZeroMQ using the PyZMQ Python bindings. fedmsg aims to make it easy to connect services together using ZeroMQ publishers and subscribers.
You can use this python package named fedmsg to use this functionality ...
This is the source code :
import fedmsg
from fedmsg import *

import os
# Set the routing_nitpicky flag to True
os.environ['FEDMSG_ROUTING_NITPICKY'] = 'True'


config = fedmsg.config.load_config([],None)
config['mute'] = True
config['timeout'] = 0

for name, endpoint, topic, msg in fedmsg.tail_messages(**config):
    print ("name ", name)
This is the result :
[mythcat@fedora FedoraMessaging]$ python fedmsg_001.py
No routing policy defined for "org.fedoraproject.prod.copr.build.start" but routing_nitpicky is False so the message is being treated as authorized.
name  fedora-infrastructure
No routing policy defined for "org.fedoraproject.prod.copr.chroot.start" but routing_nitpicky is False so the message is being treated as authorized.
name  fedora-infrastructure
No routing policy defined for "org.fedoraproject.prod.github.check_run" but routing_nitpicky is False so the message is being treated as authorized.
name  fedora-infrastructure
No routing policy defined for "org.fedoraproject.prod.github.pull_request_review" but routing_nitpicky is False so the message is being treated as authorized.
name  fedora-infrastructure
No routing policy defined for "org.fedoraproject.prod.github.pull_request_review_comment" but routing_nitpicky is False so the message is being treated as authorized.
name  fedora-infrastructure ... 

Saturday, March 30, 2024

Fedora 41 : Memstrack tool.

A runtime memory allocation tracer, like a hot spot analyzer for memory allocation, can help analyze overall memory usage, peak memory usage, kernel module memory usage, all combined with stacktrace. Userspace memory trace is planned and not yet implemented.
This tool works by tracing all page-level memory allocation events in kernel (currently supports using perf or ftrace), and actively integrate the events into a stack trace tree. It can also work with kernel's page owner log file and use as a memory usage viewer.
I tested this tool today and it is quite useful for development and monitoring the operating system, it seems to work very well, you can even see in the screenshot how ...
You can find this project on the GitHub repo.

Friday, March 22, 2024

News : Flutter on Fedora 40 - the run debug info.

The run command comes with info about the running process, see:
[mythcat@fedora examples]$ ../flutter/bin/flutter run
Launching lib/main.dart on Linux in debug mode...
Building Linux application...                                           
Syncing files to device Linux...                                 1,488ms

Flutter run key commands.
r Hot reload. 🔥🔥🔥
R Hot restart.
h List all available interactive commands.
d Detach (terminate "flutter run" but leave application running).
c Clear the screen
q Quit (terminate the application on the device).

A Dart VM Service on Linux is available at: http://127.0.0.1:38903/k8tmzU7n0NQ=/
The Flutter DevTools debugger and profiler on Linux is available at:
http://127.0.0.1:9100?uri=http://127.0.0.1:38903/k8tmzU7n0NQ=/
If you open that URL you will see this type of informations: