하드웨어/pen tablet2025. 8. 18. 10:18

아니.. 8월 14, 15일 택배없는 날이라고 방심했더니

오라는(?) 목요일에는 안오고 갑자기 16일 토요일에 회사로 택배 도착 -_-

누가 가져가면 어떡하지 노심초사하다가 오늘 출근하니 택배 있는 곳에 잘 있다.

 

우분투에서 스타일러스는 아래와 같이 펜이 인식되지 않으면 아무것도 뜨지 않는데

 

펜으로 위를 스~윽 지나가면 아래와 같이 뜬다.

위단추는 우클릭, 아래는 용도 불명인것 같은데.. 휠 클릭으로 하면 좀 편하려나?

 

그 와중에 클릭하려고 디지타이저에 내리면서 위치가 흔들리니 클릭이 안되서 멘붕.

dpi가 높다지만 해상도도 원체 높아서 조금만 움직이면 휙휙 가버리니 이걸 어떻게 보정해서 써야하나

 

그 와중에(!)

gimp 에서 지우개 도 설정이 기본으로 안되어 있어서 찾아봐야 할 듯.

 

아. 그리고 모니터에 연결하기는

 

잘 되는데.. 4k 모니터를 90도 CW 방향으로 회전시켜 놨더니 타블렛에서 상하가 모니터 상에 좌우로 움직인다.

모니터 별로 회전방향이 다르 경우 어떻게 설정해야 하지...?

 

그런데 모니터는 세로인데 타블렛을 가로로 놓고 인식만 돌리는게 옳은...가?!

xsetwacom --set 31  Rotate ccw
xsetwacom --set 30  Rotate ccw
xsetwacom --set 29  Rotate ccw
xsetwacom --set 28  Rotate ccw
xsetwacom --set 27  Rotate ccw

[링크 : https://askubuntu.com/questions/1279910/how-to-change-tablet-orientation-with-kubuntu-18-04-and-wacom-bamboo-ctl-470]

 

+

2025.08.29

$ xsetwacom --list devices
Wacom Intuos Pro M Pen stylus    id: 9 type: STYLUS    
Wacom Intuos Pro M Pad pad       id: 10 type: PAD       
Wacom Intuos Pro M Finger touch  id: 11 type: TOUCH     
Wacom Intuos Pro M Pen eraser    id: 24 type: ERASER    
Wacom Intuos Pro M Pen cursor    id: 25 type: CURSOR    

$ xsetwacom --get 9 Rotate
none

$ xsetwacom --get 10 Rotate
Property 'Wacom Rotation' does not exist on device.

$ xsetwacom --get 11 Rotate
none

$ xsetwacom --get 24 Rotate
none

$ xsetwacom --get 25 Rotate
none

이름을 쳐도 되고 id를 쳐도 되는데

stylus의 방향을 바꾸어야 하는데.. 모니터 별로 설정되는게 아니다 보니

모니터 하나가 90도 돌려져 있으면 해당 모니터 갈때만 명령어로 stylus의 방향을 돌려주어야 한다. 드럽게 귀찮네 -_-

 

다만 타블렛이 가로인데 모니터가 세로면 비율이 안맞으니까

Area를 같이 비슷한 비율로 맞춰주는것도 방법일듯 하다.

'하드웨어 > pen tablet' 카테고리의 다른 글

wacom 진단  (0) 2025.08.18
wacom on window  (2) 2025.08.18
wacom 펜 설명이 왜 이러냐 -_-  (0) 2025.08.14
wacom 의 세계..(?) - 아트 펜  (0) 2025.08.12
ubuntu wacom 타블렛 지원 .. part 2?  (1) 2025.08.12
Posted by 구차니

8시 부터 8시 까지 자버린듯

4시간 자고 활동은 오라지게 해서 피 갂으면서 깨어있었다는 느낌이었는데

그렇게 훅 가버릴 줄이야.. -_-

 

그 와중에 일요일은 열심히 홈월드 리마스터 1편...

데저트 오브 카락 언제 하지?

'개소리 왈왈 > 육아관련 주저리' 카테고리의 다른 글

애견미용이 비싸서!  (0) 2025.08.23
다시 돌아온 열대야  (0) 2025.08.19
시승(?)  (1) 2025.08.15
타이어 펑크, 교체  (0) 2025.08.13
  (0) 2025.08.03
Posted by 구차니

딸래미 친구(?) 가족 차가 9인승 디젤 카니발이래서

아내 보여는데 좋아라 한다.

흐음.. 사고 싶긴한데 고민이네

'개소리 왈왈 > 육아관련 주저리' 카테고리의 다른 글

다시 돌아온 열대야  (0) 2025.08.19
하루 늦은.. 기절?  (0) 2025.08.17
타이어 펑크, 교체  (0) 2025.08.13
  (0) 2025.08.03
더워서 멀 못해먹겠네  (0) 2025.07.27
Posted by 구차니

얼굴을 어떻게 인식하나 해서 찾아보는 중

코드에서 아래의 내용이 있어 보니 cosine similarity 라고 나오는데

 

    def get_similarity(self, face_a, face_b):
        """Finds the similarity between two masks
        This is done by taking the vectors in the face mask and finding the
        cosine similarity between them. The formula to find this is:

                                  f(a[n] * b[n])
        sim (a[],b[]) = -----------------------------------
                         sqrt(f(a[n]^2)) * sqrt(f(b[n]^2))

        where:
        - a[] and b[] both represent the array of values of a single face mask
        - f(n) is the sum of values where n is 0 through the length of a[]
          minus 1
        - a[] and b[] have equal lengths and equal indexes map to the same
          points on the face mask

        The idea behind this method is that vectors that have smaller
        vectors between them (independent of magnitude) should in theory be
        similar.
        """
        dot = 0
        a_sum = 0
        b_sum = 0
        for count in range(128):
            dot = dot + (face_a[count] * face_b[count])
            a_sum = a_sum + (face_a[count] * face_a[count])
            b_sum = b_sum + (face_b[count] * face_b[count])
        sim = dot / (np.sqrt(a_sum) * np.sqrt(b_sum))
        return sim

 

대충 검색해보니 취향을 찾기로도 써먹기도 한다고

[링크 : https://wikidocs.net/24603]

[링크 : https://benn.tistory.com/62]

 

[링크 : https://snu-eng.kr/html/2403/SS46_23_special.php]

 

face_recognition 라이브러리에서는 face_encodings로 특징점을 추출하고

compare_faces라는 함수로 유사도를 계산해주는 듯.

import face_recognition
known_image = face_recognition.load_image_file("biden.jpg")
unknown_image = face_recognition.load_image_file("unknown.jpg")

biden_encoding = face_recognition.face_encodings(known_image)[0]
unknown_encoding = face_recognition.face_encodings(unknown_image)[0]

results = face_recognition.compare_faces([biden_encoding], unknown_encoding)

[링크 : https://github.com/ageitgey/face_recognition]

'이론 관련 > 2D 그래픽 관련' 카테고리의 다른 글

retinex 알고리즘  (0) 2022.01.20
jpeg 헤더  (0) 2020.12.01
영상처리 관련 링크 기술  (0) 2017.04.19
HDRi / HDRI (High dynamic range imaging)  (0) 2011.04.29
BDF - Bitmap Distribution Format  (0) 2011.04.28
Posted by 구차니
embeded/i.mx 8m plus2025. 8. 14. 16:42

영상처리의 가속을 위한 크로스 플랫폼.

Portable, Power-efficient Vision Processing
OpenVX™ is an open, royalty-free standard for cross platform acceleration of computer vision applications. OpenVX enables performance and power-optimized computer vision processing, especially important in embedded and real-time use cases such as face, body and gesture tracking, smart video surveillance, advanced driver assistance systems (ADAS), object and scene reconstruction, augmented reality, visual inspection, robotics and more.

[링크 : https://www.khronos.org/openvx/]

[링크 : https://cho001.tistory.com/224]

 

소스 뒤져보다 보니 so 파일 두개가 보이는데

        if os.path.exists("/usr/lib/libtim-vx.so"):
            backends_available = ["NPU", "CPU"]
            
            ext_delegate = tflite.load_delegate("/usr/lib/libvx_delegate.so")

 

libtim-vx.so는 openVX를 통해 가속받는 VeriSilicon 사의 Tensor Interface Module 을 위한 라이브러리이고

[링크 : https://github.com/VeriSilicon/TIM-VX]

 

libvx_delegate.so 는 openVX 함수를 위한 것인듯 한데..

[링크 : https://github.com/nxp-imx/tflite-vx-delegate-imx]

 

verisilicon 으로 검색하면 vivante NPU IP 를 소유하고 있는 것으로 보인다.

NXP 에서 vivante GPU를 구매해서 GC7000UL을 i.mx8mp에 넣은것 같다.

그러다 보니 gpu / npu를 통일 업체걸로 구매한 듯.

[링크 : https://www.verisilicon.com/en/IPPortfolio/VivanteNPUIP]

'embeded > i.mx 8m plus' 카테고리의 다른 글

eqi - model tool  (0) 2025.08.22
NNstreamer - tensor*  (0) 2025.08.18
gstreamer pipeline / appsink  (0) 2025.08.14
nxp eiq 우분투 실행 실패  (0) 2025.07.31
nxp g2d_blit  (0) 2025.04.01
Posted by 구차니
하드웨어/pen tablet2025. 8. 14. 16:07

2017을 안봤는데, 이게 pth-660 이었으니.. 또 다른 세대가 되는건가 보다.

 

[링크 : https://www.wacom.com/en-in/products/wacom-intuos-pro-2017]

 

이전 세대의 Intuos Pro / Cintiq의 펜을 Wacom Intuos Pro (2017)에도 같이 사용할 수 있습니까?

예,  이전 세대 Wacom 제품의 펜을 일부 사용할 수 있습니다. 하지만 이전 세대 제품에는  Wacom Intuos Pro 타블렛에 포함 된 Pro Pen 2를 사용할 수는 없습니다. 

프로 펜 (KP503E): 대중적인  Wacom 펜 기능을 제공하는 인체 공학적 디자인의 펜. 새로운 Wacom Intuos Pro에서 이 펜을 사용하면 8192가 아닌 2048 개의 압력 수준이 제공됩니다.

아트 펜 (KP701E2): 가장 인기있는 액세서리 펜은 회전 브러시, 마커, 서예 펜 및 기타 자연 매체 도구의 느낌을 제공합니다. 라운드 또는 끌 포인트 펜촉과 함께 사용하십시오. 응용 프로그램 소프트웨어 지원이 필요합니다. 새로운 Wacom Intuos Pro에서 이 펜을 사용하면 8192가 아닌 2048 개의 압력 수준이 제공됩니다.

클래식 펜 (KP300E2): 더 얇은 펜을 선호하는 사람들을 위해 디자인 되었기 때문에 표준 그립 펜 대신 사용할 수 있습니다. 새로운 Wacom Intuos Pro에서 이 펜을 사용하면 8192 에어 브러시 (KP400E2)가 아닌 2048 개의 압력 레벨이 제공됩니다. 에어 브러시 효과를 선호하는 사람들을 위해 설계되었습니다. 새로운 Wacom Intuos Pro에서이 펜을 사용하면 8192가 아닌 2048 개의 압력 수준이 제공됩니다.

그립 펜 (KP501E2): 모든 인기있는 Wacom 펜 기능을 제공하는 인체 공학적 디자인의 펜. 새로운 Wacom Intuos Pro에서이 펜을 사용하면 8192가 아닌 2048 개의 압력 수준이 제공됩니다. 이전 세대 제품에 Wacom Intuos Pro 태블릿에 포함 된 Pro Pen 2를 사용할 수 없습니다.

[링크 : https://support.wacom.com/hc/ko/articles/1500006330202-이전-세대의-Intuos-Pro-Cintiq의-펜을-Wacom-Intuos-Pro-2017-에도-같이-사용할-수-있습니까]

 

KP-504E-00DZX
와콤 프로펜 2

호환 가능한 제품
와콤 인튜어스 프로 (PTH-460, PTH-660, PTH-860)

[링크 : https://estore.wacom.kr/ko-kr/wacom-pro-pen-2-with-case-kp-504e-00dzx.html?srsltid=AfmBOookbDl3GScasFTMDi3Y2vBfRnZrl7Z_osQjuaG6TdNo7d1D4nl7]

 

KP-501E-01DBC
그립펜 - 인튜어스 4/5 & 구형 신티크 모델 용

호환 가능한 제품
인튜어스 프로 (PTH-451, PTH-651, PTH-851)

[링크 : https://estore.wacom.kr/ko-kr/intuos4-5-cintiq-2nd-gen-grip-pen-kp-501e-01dbc.html?srsltid=AfmBOopt-FrsiFWA9_fc8GwJw8qx4qyVtl_kjjJdLVzKyt9-amdwyDjF]

 

 

'하드웨어 > pen tablet' 카테고리의 다른 글

wacom on window  (2) 2025.08.18
wacom 펜 도착!  (0) 2025.08.18
wacom 의 세계..(?) - 아트 펜  (0) 2025.08.12
ubuntu wacom 타블렛 지원 .. part 2?  (1) 2025.08.12
xsetwacom with intuos pro  (0) 2025.08.08
Posted by 구차니
embeded/i.mx 8m plus2025. 8. 14. 15:07

nxp i.mx8mp 예제를 뜯어 보다가 신기한 걸 발견. 저렇게 해서 성능이 잘 나왔던건가?

            cam_pipeline = cv2.VideoCapture(
                "v4l2src device=" + cam + " ! imxvideoconvert_g2d ! "
                "video/x-raw,format=RGBA,width="
                + str(self.width)
                + ",height="
                + str(self.height)
                + " ! "
                + "videoconvert ! appsink"
            )

        status, org_img = cam_pipeline.read()

[링크 : https://gstreamer.freedesktop.org/documentation/applib/gstappsink.html?gi-language=c]

 


+

i.mx8mp 에서 해보니 비디오 받아오는게 느린게 아니라서 위의 파이프라인을 넣어도 느린건 여전하다.

+

 

cv::VideoCapture::VideoCapture ( const String &  filename, int  apiPreference)

Open video file or a capturing device or a IP video stream for video capturing with API Preference.
This is an overloaded member function, provided for convenience. It differs from the above function only in what argument(s) it accepts.

Parameters
filename it can be:
name of video file (eg. video.avi)
or image sequence (eg. img_%02d.jpg, which will read samples like img_00.jpg, img_01.jpg, img_02.jpg, ...)
or URL of video stream (eg. protocol://host:port/script_name?script_params|auth)
or GStreamer pipeline string in gst-launch tool format in case if GStreamer is used as backend Note that each video stream or IP camera feed has its own URL scheme. Please refer to the documentation of source stream to know the right URL.
apiPreference preferred Capture API backends to use. Can be used to enforce a specific reader implementation if multiple are available: e.g. cv::CAP_FFMPEG or cv::CAP_IMAGES or cv::CAP_DSHOW.

See also
cv::VideoCaptureAPIs

[링크 : https://docs.opencv.org/3.4/d8/dfe/classcv_1_1VideoCapture.html#a949d90b766ba42a6a93fe23a67785951]

 

camSet='v4l2src device=/dev/video0 ! video/x-raw,width=640,height=360 ! nvvidconv flip-method='+str(flip)+' \
        ! video/x-raw(memory:NVMM), format=I420, width=640, height=360 ! nvvidconv ! video/x-raw, format=BGRx ! videoconvert \
        ! video/x-raw, format=BGR enable-max-performance=1 ! appsink '
cam=cv2.VideoCapture(camSet,cv2.CAP_GSTREAMER)

[링크 : https://stackoverflow.com/questions/71816725/streaming-opencv-videocapture-frames-using-gstreamer-in-python-for-webcam]

 

CAP_GSTREAMER 
Python: cv.CAP_GSTREAMER
GStreamer.

[링크 : https://docs.opencv.org/3.4/d4/d15/group__videoio__flags__base.html#gga023786be1ee68a9105bf2e48c700294da38dcac6866f7608675dd35ba0b9c3c07]

 

appsink 예제

[링크 : https://makepluscode.tistory.com/entry/Gstreamer-Python-Appsink-구현하기] python

[링크 : https://ralpioxxcs.github.io/post/gstreamer/1_gst/] cpp

'embeded > i.mx 8m plus' 카테고리의 다른 글

NNstreamer - tensor*  (0) 2025.08.18
openVX, verisilicon(vivante)  (0) 2025.08.14
nxp eiq 우분투 실행 실패  (0) 2025.07.31
nxp g2d_blit  (0) 2025.04.01
sounddevice on arm i.mx8 evk  (0) 2024.05.14
Posted by 구차니
embeded/odroid2025. 8. 13. 21:08

pip 로 face-recognition 패키지를 멀티코어 빌드 하다가

버벅하더니 맛이 가버림.. 리부팅 몇번해도 안살아 나서 화면 달아서 해보니 영 시원찮아짐

 

메모리가 2GB 밖에 안되는데 4개 코어 돌려서 죽었나..

아니면 다이소 5천원 32GB axxen 중국산 sd라 망가졌나(class 10이라 sandisk보다 선호)

어느쪽이려나..

 

Bus error

real    11m49.128s
user    27m32.299s
sys     1m0.566s

Broadcast message from systemd-journald@odroidc2 (Wed 2025-08-13 20:37:57 KST):

systemd[1]: Caught <BUS> from PID -1445126080.


Broadcast message from systemd-journald@odroidc2 (Wed 2025-08-13 20:37:57 KST):

systemd[1]: Caught <BUS>, core dump failed (child 9885, code=killed, status=7/BUS).


Broadcast message from systemd-journald@odroidc2 (Wed 2025-08-13 20:37:57 KST):

systemd[1]: Freezing execution.
Posted by 구차니

패키지를 삭제했는데 바로 재설치가 되서

캐시되었다는 말을 검색해보니 cache purge를 통해 완전히 날리고 설치할수 있다고 한다.

 

해보니 확실히 처음부터 하긴 한다.

$ time CMAKE_BUILD_PARALLEL_LEVEL=3 pip3 uninstall --break-system-packages -v dlibFound existing installation: dlib 20.0.0
Uninstalling dlib-20.0.0:
  Would remove:
    /home/minimonk/.local/lib/python3.12/site-packages/_dlib_pybind11.cpython-312-aarch64-linux-gnu.so
    /home/minimonk/.local/lib/python3.12/site-packages/dlib-20.0.0.dist-info/INSTALLER
    /home/minimonk/.local/lib/python3.12/site-packages/dlib-20.0.0.dist-info/METADATA
    /home/minimonk/.local/lib/python3.12/site-packages/dlib-20.0.0.dist-info/RECORD
    /home/minimonk/.local/lib/python3.12/site-packages/dlib-20.0.0.dist-info/WHEEL
    /home/minimonk/.local/lib/python3.12/site-packages/dlib-20.0.0.dist-info/licenses/LICENSE.txt
    /home/minimonk/.local/lib/python3.12/site-packages/dlib-20.0.0.dist-info/top_level.txt
    /home/minimonk/.local/lib/python3.12/site-packages/dlib/__init__.py
    /home/minimonk/.local/lib/python3.12/site-packages/dlib/__pycache__/__init__.cpython-312.pyc
  Will actually move:
    /home/minimonk/.local/lib/python3.12/site-packages/_dlib_pybind11.cpython-312-aarch64-linux-gnu.so
    /home/minimonk/.local/lib/python3.12/site-packages/dlib-20.0.0.dist-info/
    /home/minimonk/.local/lib/python3.12/site-packages/dlib/
Proceed (Y/n)? y
  Removing file or directory /home/minimonk/.local/lib/python3.12/site-packages/_dlib_pybind11.cpython-312-aarch64-linux-gnu.so
  Removing file or directory /home/minimonk/.local/lib/python3.12/site-packages/dlib-20.0.0.dist-info/
  Removing file or directory /home/minimonk/.local/lib/python3.12/site-packages/dlib/
  Successfully uninstalled dlib-20.0.0

real    0m4.584s
user    0m2.585s
sys     0m0.381s

$ time CMAKE_BUILD_PARALLEL_LEVEL=3 pip3 install --break-system-packages -v dlib
Using pip 24.0 from /usr/lib/python3/dist-packages/pip (python 3.12)
Defaulting to user installation because normal site-packages is not writeable
Collecting dlib
  Using cached dlib-20.0.0-cp312-cp312-linux_aarch64.whl
Installing collected packages: dlib
Successfully installed dlib-20.0.0

real    0m4.876s
user    0m4.363s
sys     0m0.347s


pip3 cache purge
Files removed: 54

 

[링크 : https://ufris.tistory.com/61]

'Programming > python(파이썬)' 카테고리의 다른 글

python simsimd  (0) 2025.08.28
python 원하는 버전 설치 및 연결하기  (0) 2025.08.26
pip install cmake build multi core support  (0) 2025.08.13
python 빌드 정보  (0) 2025.08.04
python용 얼굴탐지, 인식  (0) 2025.08.04
Posted by 구차니

pip로 설치되는 녀석중 빌드가 필요한 녀석이 있는데

dlib가 원인을 알수 없으나(?) odroid-c2 / armbian 에서 1코어만 빌드하지만

nxp imx8mp evk 에서는 3코어로 빌드해서 어떤 옵션을 주어야 되는지

웬만한건 다 검색하고 해봐도 안되서 cmake 환경변수로 찾아보니 먼가 나왔고 시도하니 된다!

 

$ pip3 install  --break-system-packages -v dlib
  Invoking CMake build: 'cmake --build . --config Release -- -j1'
  [  1%] Building CXX object dlib_build/CMakeFiles/dlib.dir/base64/base64_kernel_1.cpp.o

 

CMAKE_BUILD_PARALLEL_LEVEL=4 pip3 install  --break-system-packages -v dlib
  Invoking CMake build: 'cmake --build . --config Release -- -j4'
  [  3%] Building CXX object dlib_build/CMakeFiles/dlib.dir/bit_stream/bit_stream_kernel_1.cpp.o
  [  3%] Building CXX object dlib_build/CMakeFiles/dlib.dir/bigint/bigint_kernel_2.cpp.o
  [  2%] Building CXX object dlib_build/CMakeFiles/dlib.dir/bigint/bigint_kernel_1.cpp.o

[링크 : https://cmake.org/cmake/help/latest/envvar/CMAKE_BUILD_PARALLEL_LEVEL.html#cmake-build-parallel-level]

'Programming > python(파이썬)' 카테고리의 다른 글

python 원하는 버전 설치 및 연결하기  (0) 2025.08.26
pip 패키지 완전 삭제하기  (0) 2025.08.13
python 빌드 정보  (0) 2025.08.04
python용 얼굴탐지, 인식  (0) 2025.08.04
python struct  (0) 2024.12.13
Posted by 구차니