일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | ||||||
2 | 3 | 4 | 5 | 6 | 7 | 8 |
9 | 10 | 11 | 12 | 13 | 14 | 15 |
16 | 17 | 18 | 19 | 20 | 21 | 22 |
23 | 24 | 25 | 26 | 27 | 28 |
- C#
- pytorch
- Selenium
- error
- Docker
- 기타 연주
- pandas
- LIST
- mysql
- C
- Numpy
- paramiko
- JSON
- Linux
- label
- VS Code
- 오류
- pip
- ubuntu
- 프로그래머스
- 채보
- 컨테이너
- windows forms
- C++
- Visual Studio
- Python
- YOLO
- SSH
- 핑거스타일
- OpenCV
- Today
- Total
목록분류 전체보기 (322)
기계는 거짓말하지 않는다
![](http://i1.daumcdn.net/thumb/C150x150/?fname=https://blog.kakaocdn.net/dn/czOA6x/btrDTsFdTQx/cQCCKgmZ7Ibgd754fkprT1/img.png)
VS 2017 이상에서 지원된다. 현재 VS 2022 에서 사용중이다. Visual Studio Market Place - Word Highlight With Margin VS 메뉴의 확장 - 확장 관리에서 확인할 수 있다. 마우스나 키보드로 단어를 선택하면 현재 코드에서 현재 선택된 단어의 모든 항목을 검색하고 강조 표시한다. 설치 후 VS 메뉴의 도구 - Word Highlight settings 에서 설정을 변경할 수 있다.
![](http://i1.daumcdn.net/thumb/C150x150/?fname=https://blog.kakaocdn.net/dn/cQEQUf/btrDTswMuli/1bRhqGd1pK9vSpbI79GcCk/img.png)
root 계정으로 SSH 접속 시 기본 설정은 로그인이 되지 않는다. /etc/ssh/sshd_config 를 편집기로 편집한다. PermitRootLogin 주석을 해제하고 yes로 변경한다.
xmin, ymin, xmax, ymax 좌표를 YOLO label 형식인 center x, center y, width, height 로 변환한다. 원본 이미지 해상도를 나누어 0~1 사이의 비율로 표현한다. 다른 형식으로 된 원본 좌표도 계산 식을 변경하여 응용 가능하다. def get_object_params(i_width: int, i_height: int, xmin, ymin, xmax, ymax): image_width = 1.0 * i_width image_height = 1.0 * i_height center_x = xmin + 0.5 * (xmax - xmin) cneter_y = ymin + 0.5 * (ymax - ymin) absolute_width = xmax - xmin abso..
watch 명령어는 임의의 명령어를 일정한 시간 간격으로 터미널 창에 결과를 표시하는데 사용된다. watch [OPTIONS] COMMAND 와 같이 사용한다. 기본 간격은 2초이다. watch --help 명령으로 사용법을 볼 수 있다. -d 옵션은 이전 출력 결과와 비교하여 바뀐 부분을 표시한다. 명령어에 띄어쓰기가 포함되면 '명령어'로 묶는다. ('' 사용) 예) watch date watch -n 3 nvidia-smi watch -n 4 'cat temp_text.txt'
Python 3.6 configparser Docs 14.2. configparser — Configuration file parser — Python 3.6.15 문서 14.2. configparser — Configuration file parser Source code: Lib/configparser.py This module provides the ConfigParser class which implements a basic configuration language which provides a structure similar to what’s found in Microsoft Windows INI file docs.python.org configparser의 key에 대문자를 작성해도 confi..
C언어 파일 존재여부 확인 Linux #include if( access( f_path, F_OK ) != -1 ) { // 파일 존재 } else { // 파일 없음 } stat 구조체 이용 #include bool exist_file (char *file_name) { struct stat buffer; return (stat (file_name, &buffer) == 0); } FILE 구조체 이용 #include FILE *file; if (file = fopen("temp.txt", "r")) { fclose(file); printf("파일 존재\n"); } else { printf("파일 없음\n"); }
number = 3.141592 number2 = 10.7562149 # round 반올림 print(round(number, 2)) # 3.14 print(round(number)) # 3 print(round(number2)) # 11 number = round(number, 3) print(number) # 3.142 # 출력 시 제한 print(f"{number2:.2f}") # 10.76 print("{:.4f}, {:.5f}".format(number2, number2)) # 10.7562, 10.75621
프로그램 실행 중 발생하는 오류를 처리한다. 다음은 예제 코드이다. private void ThreadStart() { try { argsThread = new Thread(new ParameterizedThreadStart(TempFunction)); argsThread.Start(tempArgs); Thread.Sleep(interval); } } catch (ThreadInterruptedException) { MessageBox.Show("thread interrupted", "확인"); } catch (Exception e1) { MessageBox.Show(e1.Message + "\r\nLocation: ThreadStart", "오류", MessageBoxButtons.OK, Message..