본문 바로가기

세계정복의주인장

(1151)
NLP 기초 자연어 representation ML 흐름 1. 단어 임베딩 단어를 숫자로 표현하는것 == 단어의 벡터값를 보면 그 단어를 안다 단어와 단어의 의미를 수치화 했지만, 문장의 의미는 알수가 없음 2. RNN & seq2seq RNN == 데이터를 순서대로 넣으면(입력값) 값이 잘 나오네? *인코더 -> 압축 / 디코더 -> 확대 seq2seq == 문장(질문)의 단어를 순서대로 넣으면 문장(답변)을 순서대로 나오게끔! 순서대로 넣는건 입력값이 많아질수록 연산량이 폭팔적으로 증가 (무조건 순서대로 연상하므로 병렬 불가 ) -> 문장이 길어지면 앞에 값에 대한 의미가 사라짐 -> 순서가 들어간건 좋은데, 너무 많은 양은 어떻게 처리하지?? 3. 트랜스퍼머 트랜스포머 == 순서대로 넣긴하는데, 위치정보도 같이..
input vs sys.stdin.readline 결론 : input()이 syscall에 의해 실행될 때마다 TTY인지 확인하고 sys.stdin.readline()보다 훨씬 느리게 작동 대략 속도 30배 정도 차이남!!! 빌트인 함수 input과 sys.stdin.readline함수는 정확히 같은 일을 하지 않는다. 어떤 것이 더 빠른지는 수행 중인 작업의 세부 사항에 따라 달라질 수 있다. 첫 번째 차이점은 input인터프리터가 대화식으로 실행 중인 경우 표시되는 선택적 프롬프트 매개변수가 있다는 것. 이로 인해 프롬프트가 비어 있더라도(default는 비어있음) 약간의 오버헤드가 발생한다. 두번째 차이점은 input은 개행을 제거한다. 마지막 차이는 입력의 끝이 표시되는 방식이다. input은 호출할 때 입력이 더이상 없다면 EOF 오류를 발생시..
[baekjoon] dijkstra 문제들 https://www.acmicpc.net/problem/1261 1261번: 알고스팟 첫째 줄에 미로의 크기를 나타내는 가로 크기 M, 세로 크기 N (1 ≤ N, M ≤ 100)이 주어진다. 다음 N개의 줄에는 미로의 상태를 나타내는 숫자 0과 1이 주어진다. 0은 빈 방을 의미하고, 1은 벽을 의미 www.acmicpc.net https://www.acmicpc.net/problem/2665 2665번: 미로만들기 첫 줄에는 한 줄에 들어가는 방의 수 n(1 ≤ n ≤ 50)이 주어지고, 다음 n개의 줄의 각 줄마다 0과 1이 이루어진 길이가 n인 수열이 주어진다. 0은 검은 방, 1은 흰 방을 나타낸다. www.acmicpc.net https://www.acmicpc.net/problem/1835..
http status 307 개발 진행중 307 status를 처음 발견해서 포스팅한다. 아래 그림을 보면 첫번째 notice/ 로 put을 날렸는데, 서버에서 307을 리턴하고 바로 다음 notice로 다시 put이 가는 상황이다. 사실 별건 아니고, 요청한 body값을 재사용하기 위한 status값으로 똑같은 body값을 반환하며 notice/ → notice 로 response headers에 location에 변경한것을 볼수 있다. 동작에는 아무런 문제가 없지만 결국 요청이 두번가는 것이다. 요청에 대한 사소한 실수로 “/” 를 빼면 요청이 한번만 가는것을 확인했다. 요런 사소한 실수를 없애면 더욱 비용 절감되지 않을까? 참고사항 https://developer.mozilla.org/en-US/docs/Web/HTTP/Sta..
ubuntu 크롬드라이버 && 크롬 브라우저 설치 링크 사이트 맨날 버전 않맞아서 찾다가 여기에 기록...제발 그만 찾기를...ㅜㅡㅜ https://chrome-versions.com/ Index of / chrome-versions.com https://chromedriver.chromium.org/downloads ChromeDriver - WebDriver for Chrome - Downloads Current Releases If you are using Chrome version 110, please download ChromeDriver 110.0.5481.77 If you are using Chrome version 109, please download ChromeDriver 109.0.5414.74 If you are using Chrome versi..
[leetcode] dijkstra https://leetcode.com/problems/network-delay-time/description/ Network Delay Time - LeetCode Network Delay Time - You are given a network of n nodes, labeled from 1 to n. You are also given times, a list of travel times as directed edges times[i] = (ui, vi, wi), where ui is the source node, vi is the target node, and wi is the time it takes for a leetcode.com https://leetcode.com/problems/path-wi..
[leetcode] dfs / bfs 재밌는 문제들 https://leetcode.com/problems/surrounded-regions/ Surrounded Regions - LeetCode Surrounded Regions - Given an m x n matrix board containing 'X' and 'O', capture all regions that are 4-directionally surrounded by 'X'. A region is captured by flipping all 'O's into 'X's in that surrounded region. Example 1: [https://assets.leetcode. leetcode.com https://leetcode.com/problems/count-servers-that-com..
[leetcode] dfs/bfs 섬 문제들 https://leetcode.com/problems/number-of-islands/ Number of Islands - LeetCode Number of Islands - Given an m x n 2D binary grid grid which represents a map of '1's (land) and '0's (water), return the number of islands. An island is surrounded by water and is formed by connecting adjacent lands horizontally or vertically. You may ass leetcode.com https://leetcode.com/problems/island-perimeter/ Is..