일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
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 | 29 | 30 | 31 |
- word2vec
- 지마켓
- 게시판 만들기
- mysql
- pytorch
- 크롤링
- Gmarket
- java
- 이력서
- jsp 파일 설정
- Topics
- Websocket
- 파이썬
- db
- oracle
- 토픽추출
- 과학백과사전
- Python
- 자바
- 幼稚园杀手(유치원킬러)
- test
- 네이버뉴스
- lda
- 코사인 유사도
- tomoto
- RESFUL
- (깃)git bash
- 방식으로 텍스트
- spring MVC(모델2)방식
- r
- Today
- Total
목록Python (125)
무회 Blog
import re class Cleaning_Text: def comMonText_biyur(original_tokenList, gensim_tokenList1): _topFreqOriginal = Counter(original_tokenList) _topFreqGensim1 = Counter(gensim_tokenList1) ### 교집합 comMon1_1 = _topFreqOriginal & _topFreqGensim1 # 교집합 빈도수 most_cnt = 50 ## 상위 50개 comMon1_1 = comMon1_1.most_common(most_cnt) # _topFreqGensim if len(original_tokenList) == 0: biyur = 0 else: biyur1_1 = roun..
소스: 1) 서버 소스 (python) websocket_server.py import asyncio # 웹 소켓 모듈을 선언한다. import websockets # 클라이언트 접속이 되면 호출된다. async def accept(websocket, path): while True: # 클라이언트로부터 메시지를 대기한다. data = await websocket.recv(); print("receive : " + data); # 클라인언트로 echo를 붙여서 재 전송한다. await websocket.send("echo : " + data); # 웹 소켓 서버 생성.호스트는 localhost에 port는 9998로 생성한다. start_server = websockets.serve(accept, "lo..
소스: 1) 서버 소스 (python) websocket_server.py import asyncio # 웹 소켓 모듈을 선언한다. import websockets # 클라이언트 접속이 되면 호출된다. async def accept(websocket, path): while True: # 클라이언트로부터 메시지를 대기한다. data = await websocket.recv(); print("receive : " + data); # 클라인언트로 echo를 붙여서 재 전송한다. await websocket.send("echo : " + data); # 웹 소켓 서버 생성.호스트는 localhost에 port는 9998로 생성한다. start_server = websockets.serve(accept, "lo..
websocket_client.py ############################################################### #!/usr/bin/env python # WS client example import asyncio import websockets async def hello(): uri = "ws://localhost:8765" async with websockets.connect(uri) as websocket: name = input("What's your name? ") await websocket.send(name) print(f"> {name}") greeting = await websocket.recv() print(f"< {greeting}") async..
## REST_ FUL 셋팅 import requests import json from bs4 import BeautifulSoup as bs tt = input API_HOST = 'http://localhost:8080/' _headers = {'Authorization': 'User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/84.0.4147.135 Safari/537.36'} def req(path, query, method, data={}): url = API_HOST + path if method == 'GET': return requests.get(url, heade..