Skip to content

Instantly share code, notes, and snippets.

View bhomaidan1990's full-sized avatar
🐐
Trying . . .

Belal Hmedan bhomaidan1990

🐐
Trying . . .
  • UGA
  • France - Grenoble
View GitHub Profile
@bhomaidan1990
bhomaidan1990 / output.png
Created May 14, 2023 15:23 — forked from endolith/output.png
Detecting rotation and line spacing of image of page of text using Radon transform
output.png
@bhomaidan1990
bhomaidan1990 / setup-azure-kinect-on-jetson-x-nx.md
Created April 1, 2023 13:34 — forked from madelinegannon/setup-azure-kinect-on-jetson-x-nx.md
Notes on Setting up the Microsoft Azure Kinect on Ubuntu 18.04
@bhomaidan1990
bhomaidan1990 / potentialfield.cpp
Created March 17, 2023 09:32 — forked from anonymous/potentialfield.cpp
This piece of code was written for a robot that needs to solve a maze autonomously. Using its laser range finder data, the detected wall points are given a repelling force as function of the distance. Then, the desired target is given an attracting force. The code finally returns a net force vector, in whose direction the robot should start driv…
#include "potentialfield.h"
// CONSTRUCTOR OF POTENTIALFIELD
PotentialField::PotentialField()
{
rMult = 15.0;
meanNumber = 8;
maxPointDiff = 0.05;
}
@bhomaidan1990
bhomaidan1990 / NUMA node problem.md
Created February 26, 2023 20:16 — forked from zrruziev/NUMA node problem.md
Fixing "successful NUMA node read from SysFS had negative value (-1), but there must be at least one NUMA node, so returning NUMA node zero" problem

What is NUMA (Non-Uniformed Memory Access)

Non-Uniform Memory Access (NUMA) is one of the computer memory design methods used in multiprocessor systems, and the time to access the memory varies depending on the relative position between the memory and the processor. In the NUMA architecture, when a processor accesses its local memory, it is faster than when it accesses the remote memory. Remote memory refers to memory that is connected to another processor, and local memory refers to memory that is connected to its own processor. In other words, it is a technology to increase memory access efficiency while using multiple processors on one motherboard. When a specific processor runs out of memory, it monopolizes the bus by itself, so other processors have to play. , and designate 'access only here', and call it a NUMA node.

1. Check Nodes

lspci | grep -i nvidia
  
01:00.0 VGA compatible controller: NVIDIA Corporation TU106 [GeForce RTX 2060 12GB] (rev a1)
@bhomaidan1990
bhomaidan1990 / foo.js
Created January 18, 2023 05:35 — forked from minshallj/foo.js
roslibjs example
//* The Ros object, wrapping a web socket connection to rosbridge.
var ros = new ROSLIB.Ros({
url: 'ws://localhost:9090' // url to your rosbridge server
});
//* A topic for messaging.
var exampleTopic = new ROSLIB.Topic({
ros: ros,
name: '/com/endpoint/example', // use a sensible namespace
messageType: 'std_msgs/String'
@bhomaidan1990
bhomaidan1990 / webpack.config.js
Created October 27, 2022 06:12 — forked from xpepermint/webpack.config.js
Vue.js webpack.config.js
var path = require('path');
var webpack = require('webpack');
var isProduction = process.env.NODE_ENV === 'production';
/*
* Compile for usage in a browser-like environmen or for the server.
*/
exports.target = 'web';
@bhomaidan1990
bhomaidan1990 / mydiss.cls
Created June 4, 2022 19:04 — forked from ummels/mydiss.cls
Class file for my PhD thesis
% Copyright (c) 2010 Michael Ummels <michael@ummels.de>
%
% Permission to use, copy, modify, and/or distribute this software for any
% purpose with or without fee is hereby granted, provided that the above
% copyright notice and this permission notice appear in all copies.
%
% THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
% WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
% MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
% ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
@bhomaidan1990
bhomaidan1990 / boost-windows.md
Created January 28, 2022 18:26 — forked from sim642/boost-windows.md
Installing boost libraries for GCC (MinGW) on Windows

Installing boost libraries for GCC (MinGW) on Windows

Folder setup

  1. Extract downloaded boost source, e.g. C:\Program Files\boost_1_59_0.
  2. Create a folder for Boost.Build installation, e.g. C:\Program Files\boost-build.
  3. Create a folder within for building, i.e. C:\Program Files\boost_1_59_0\build.
  4. Create a folder for installation, e.g. C:\Program Files\boost.

GCC setup

  1. Open Command Prompt.
@bhomaidan1990
bhomaidan1990 / opencv.md
Last active March 8, 2022 05:52
OpenCV compile instructions
cmake -D CMAKE_BUILD_TYPE=RELEASE \
-D WITH_QT=ON \
-D WITH_VTK=OFF \
-D CMAKE_INSTALL_PREFIX=/usr/local \
-D INSTALL_C_EXAMPLES=ON \
-D INSTALL_PYTHON_EXAMPLES=ON \
-D OPENCV_GENERATE_PKGCONFIG=ON \
-D OPENCV_EXTRA_MODULES_PATH=../../opencv_contrib/modules \
-D BUILD_EXAMPLES=ON .. \
@bhomaidan1990
bhomaidan1990 / yumi_motion_api_node
Created October 31, 2021 20:33
YuMi Motion API Node
#!/usr/bin/python3
import sys
from math import pi as PI
import rospy
import tf
from std_msgs.msg import Float64
from geometry_msgs.msg import *
from sensor_msgs.msg import *
from moveit_msgs.msg import *