Skip to content

Instantly share code, notes, and snippets.

View tfmoraes's full-sized avatar

Thiago Franco de Moraes tfmoraes

View GitHub Profile
Mar 25 10:22:24 bluefin kernel: Linux version 6.14.0-0.rc7.56.fc42.x86_64 (mockbuild@f8900533f8d8482aaf6e1e5063eccb1a) (gcc (GCC) 15.0.1 20250228 (Red Hat 15.0.1-0), GNU ld version 2.44-3.fc42) #1 SMP PREEMPT_DYNAMIC Mon Mar 17 13:25:24 UTC 2025
Mar 25 10:22:24 bluefin kernel: Command line: BOOT_IMAGE=(hd1,gpt2)/ostree/default-b977a7f3000d6a9c9d29f7e2a83a0471a543f9309a719a40e737e784d4b35f44/vmlinuz-6.14.0-0.rc7.56.fc42.x86_64 rd.luks.uuid=luks-230af0e7-091c-4f95-ab6c-dfc1c1dc61b7 rhgb quiet root=UUID=29051c3c-4953-45af-ae96-c4d3e51f67bf rootflags=subvol=root rw ostree=/ostree/boot.1/default/b977a7f3000d6a9c9d29f7e2a83a0471a543f9309a719a40e737e784d4b35f44/0 initcall_blacklist=simpledrm_platform_driver_init
Mar 25 10:22:24 bluefin kernel: BIOS-provided physical RAM map:
Mar 25 10:22:24 bluefin kernel: BIOS-e820: [mem 0x0000000000000000-0x000000000009ffff] usable
Mar 25 10:22:24 bluefin kernel: BIOS-e820: [mem 0x00000000000a0000-0x00000000000fffff] reserved
Mar 25 10:22:24 bluefin kernel: BIOS-e820: [mem 0x00000
@tfmoraes
tfmoraes / gen_patches.patch
Created September 17, 2024 19:12
gen_patches.patch
diff --git a/invesalius/segmentation/deep_learning/segment.py b/invesalius/segmentation/deep_learning/segment.py
index 041e6f90..dc17a203 100644
--- a/invesalius/segmentation/deep_learning/segment.py
+++ b/invesalius/segmentation/deep_learning/segment.py
@@ -5,8 +5,13 @@ import pathlib
import sys
import tempfile
import traceback
+from typing import Generator, Tuple
@tfmoraes
tfmoraes / viewport_overlay.py
Created July 26, 2024 01:27
viewport_overlay.py
import sys
from typing import Optional
import numpy as np
from PySide6.Qt3DCore import Qt3DCore
from PySide6.Qt3DExtras import Qt3DExtras
from PySide6.Qt3DRender import Qt3DRender
from PySide6.QtCore import QPoint, QPointF, QRectF, QSize, QUrl
from PySide6.QtGui import QColor, QFont, QGuiApplication, QPainter, QVector3D
@tfmoraes
tfmoraes / marlin_simulator_socket.diff
Created March 19, 2024 21:45
Diff with configuration to make marlin simulator listen to socket on 8099
diff --git a/Marlin/Configuration.h b/Marlin/Configuration.h
index 4f93a4de48..8604de245a 100644
--- a/Marlin/Configuration.h
+++ b/Marlin/Configuration.h
@@ -1,6 +1,6 @@
/**
* Marlin 3D Printer Firmware
- * Copyright (c) 2020 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
+ * Copyright (c) 2021 MarlinFirmware [https://github.com/MarlinFirmware/Marlin]
*
@tfmoraes
tfmoraes / shell.nix
Created November 15, 2023 23:51
shell.nix to floem
let
pkgs = import <nixpkgs> { };
fenix = pkgs.callPackage "${
fetchTarball "https://github.com/nix-community/fenix/archive/main.tar.gz"
}"
{ };
in
pkgs.mkShell {
buildInputs = [
pkgs.wayland
@tfmoraes
tfmoraes / sphinx_doc.patch
Created August 15, 2023 22:29
sphinx_doc.patch
diff --git a/edit_documentation_here/source/conf.py b/edit_documentation_here/source/conf.py
index ac57e1d..80b505e 100644
--- a/edit_documentation_here/source/conf.py
+++ b/edit_documentation_here/source/conf.py
@@ -21,7 +21,7 @@ myst_enable_extensions = ["colon_fence"]
templates_path = ['_templates']
exclude_patterns = []
-
+numfig = True
diff --git a/invesalius/gui/network/text_panel.py b/invesalius/gui/network/text_panel.py
index ce22c2e0..6c6a5d31 100644
--- a/invesalius/gui/network/text_panel.py
+++ b/invesalius/gui/network/text_panel.py
@@ -5,6 +5,7 @@ from invesalius import inv_paths
import wx.gizmos as gizmos
import wx
import os
+import pathlib
import unittest
from unittest.mock import MagicMock
import invesalius.i18n as i18n
_ = i18n.InstallLanguage('en')
from invesalius.data.geometry import *
class TestBox(unittest.TestCase):
import sys
import vtk
def getInlet_and_Outlets(mesh):
fillHoles = vtk.vtkFillHolesFilter()
fillHoles.SetInputData(mesh)
fillHoles.SetHoleSize(1000.0)
fillHoles.Update()
import sys
import vtk
colors = vtk.vtkNamedColors()
reader = vtk.vtkSTLReader()
reader.SetFileName(sys.argv[1])
reader.Update()