Base Line
-
리스트 딥카피Base Line/python 기초 코드 2023. 8. 24. 17:13
이썬 리스트에서 a=[] 이고 tmp=[1,2,3] 라고 할때 그냥 a.append(tmp)랑 a.append(tmp[:]) 라고 한다면 a.append(tmp): 이 경우에는 리스트 a에 tmp 리스트 객체를 추가하는 것입니다. 즉, a 리스트 안에는 하나의 요소로서 tmp 리스트 전체가 들어가게 됩니다. 이후 tmp 리스트가 변경되면 a 리스트에 추가된 요소도 함께 변경될 수 있습니다. 이는 a 리스트가 tmp 리스트를 참조하고 있는 것입니다. 따라서 a[0] is tmp가 True일 것입니다. a.append(tmp[:]): 이 경우에는 tmp 리스트의 내용을 슬라이싱하여 새로운 리스트 객체를 생성한 후, 이를 a 리스트에 추가합니다. 이렇게 하면 a 리스트와 tmp 리스트는 완전히 별개의 객체가 ..
-
로컬에 포크한 깃허브 관리Base Line/github관리 2023. 8. 8. 15:30
##상황 로컬 컴퓨터에 포크한 깃헙 레포지터리와 같은 상태를 만들고 싶음!! 우선 작업하는 원본 레포지터리로 부터 포크를 했다고 가정해보자 포크한 레포지터리로 부터 로컬 컴퓨터에 클론을 진행한다. git clone https://github.com/ylab604/Algo_Master.git. cd Algo_Master 여기에 포크한 원본 레포지터리를 추가한다. git remote add upstream https://github.com/ylab604/Algo_Master.git. (여기서 upstream을 작명하는 것은 본인 마음이다 보통 upstream을 많이 사용한다.) 공통작업을 해야한다면 보통 브랜치를 생성해서 작업한다. 그치만 알고리즘 공부하는 레포지이므로 생략 ㅎㅎ 원본 레포지토리와 동기화 (..
-
데이콘 정리 이상치 탐지 1Base Line/데이콘 2023. 1. 25. 01:55
https://dacon.io/competitions/official/236036/codeshare/7506?page=1&dtype=recent [Private: 0.96225, 7th] VAE, RaPP, Residual 등 월간 데이콘 기계 고장 진단 AI 경진대회 dacon.io **허준호 님과 함께 참여했던 데이콘 이상치 탐지 후기 및 정리** 처음 만난 사람과 빠르게 협업한 경험 진동 데이터/ 음향 데이터 에 관해서 처음 다루어 본 경험 [대회배경] 이미지 데이터는 크기가 클수록 이동, 분석, 그리고 적용에 많은 비용이 발생한다는 단점이 존재. 따라서, 상대적으로 데이터 크기가 작은 음향 데이터를 활용할 수 있다면, 보다 적은 비용으로 스마트 제조 혁신을 이루어 낼 수 있을 것임. 또한 기계의 ..
-
sobel, canny, laplacian filterBase Line/python 기초 코드 2022. 12. 3. 12:16
import cv2 src = cv2.imread("normal.jpg", cv2.IMREAD_COLOR) gray = cv2.cvtColor(src, cv2.COLOR_BGR2GRAY) sobel = cv2.Sobel(gray, cv2.CV_8U, 1, 0, 3) laplacian = cv2.Laplacian(gray, cv2.CV_8U, ksize=3) canny = cv2.Canny(src, 100, 255) cv2.imwrite('normal_canny.jpg', canny) #cv2.save #cv2.imshow("sobel", sobel) #cv2.imshow("laplacian", laplacian) #cv2.imshow("canny", canny) cv2.waitKey() cv2.destr..