reducecommutetime's Introduction
reducecommutetime's People
reducecommutetime's Issues
데이터 중복이 있을 수도 있음.
2018년 3월 25일 API 결과 수집lambda 배포시에,
context.done(null, msg) 로 해야 할것을 context.done(msg) 로 작성하는 바람에,
retry가 발생했을 것으로 추정.
다행히 10~20분 만에 조치해서 많지는 않을 듯.
참고자료.
https://docs.aws.amazon.com/ko_kr/lambda/latest/dg/retries-on-errors.html
관련 스크린샷은 코멘트로
버스 정류장 얻어오는 방법
네이버 지도 데스크탑에서 개발자 도구를 통해 습득.
딱히인증은 필요 없어보이며, 있다 한들, 셀레니움으로 아이디 로그인 한번만 하면 됨.
뒷단은 https://lab.odsay.com/ 여기서 만드는 정보인듯 하다
아래는 필요 없다;
위도 경도로 장소명을 특정하는 것은 아래로 가능
https://map.naver.com/common2/searchRadius.nhn?xPos=126.9321996&yPos=37.3602801
정류장 바로 옆에 붙어있는 건물이 나올때도 있긴하지만.. 일단 그래도 딱 하나 짚어준다.
// 20190625023943
// https://map.naver.com/findroute2/searchPubtransPath.nhn?apiVersion=3&searchType=0&start=126.9458048%2C37.3528987%2C%EA%B5%B0%ED%8F%AC%EC%97%AD&destination=126.9442777%2C37.3579761%2C%EA%B5%B0%ED%8F%AC%EC%A4%91%ED%95%99%EA%B5%90
{
"error": {
"code": "-98",
"msg": "출발지와 도착지 간의 직선거리가 700m 미만인 경우, 결과를 제공하지 않습니다.",
"displayMsg": "출발지와 도착지 간의 직선거리가 700m 미만인 경우, 결과를 제공하지 않습니다.",
"start": "349509185,149283507,군포역",
"end": "349507865,149289148,군포중학교",
"pointDistance": "580",
"walkTime": "9",
"viewType": "list"
}
}
# 긴경로를 넣으면 아래정포를 포함한게 나온다.
"info": {
"mapObj": "18929:1:17:23@1142:1:3:17|0:0:0:0@0:0:0:0",
"payment": "1200",
"busTransitCount": "2",
"subwayTransitCount": "0",
"busStationCount": "20",
"subwayStationCount": "0",
"totalStationCount": "20",
"totalTime": "63",
"totalWalk": "1870",
"trafficDistance": "7147",
"totalDistance": "9017",
"firstStartStation": "초평동",
"lastEndStation": "군포중학교",
"totalWalkTime": "29",
"subwayExpress": "0"
}
},
계획
- 위 api 로 원하는 범위내 버스 정류장 습득 (지하철역 인근에 버스정류장은 반드시 있으므로 버스정류장만 알면 충분)
- 길찾기 api를 조합하여 요청, info 를 해석한다.
- 경로에 점수를 매긴다
- totalTime 이 적은게 제일 좋음
- 동률이라면 환승이 적은편으로.. (버스환승이 더 적어야함)
- 그래도 동률이라면 걷는 시간이 적은편으로
- https://map.naver.com/search2/searchBusStopWithinRectangle.nhn?bounds=126.9406669%3B37.3437333%3B126.9632415%3B37.3582671&count=100&level=14
네이버 지도 데스크탑에서 개발자 도구를 통해 습득.
딱히인증은 필요 없어보이며, 있다 한들, 셀레니움으로 아이디 로그인 한번만 하면 됨.
뒷단은 https://lab.odsay.com/ 여기서 만드는 정보인듯 하다
아래는 필요 없다;
위도 경도로 장소명을 특정하는 것은 아래로 가능
https://map.naver.com/common2/searchRadius.nhn?xPos=126.9321996&yPos=37.3602801
정류장 바로 옆에 붙어있는 건물이 나올때도 있긴하지만.. 일단 그래도 딱 하나 짚어준다.
// 20190625023943
// https://map.naver.com/findroute2/searchPubtransPath.nhn?apiVersion=3&searchType=0&start=126.9458048%2C37.3528987%2C%EA%B5%B0%ED%8F%AC%EC%97%AD&destination=126.9442777%2C37.3579761%2C%EA%B5%B0%ED%8F%AC%EC%A4%91%ED%95%99%EA%B5%90
{
"error": {
"code": "-98",
"msg": "출발지와 도착지 간의 직선거리가 700m 미만인 경우, 결과를 제공하지 않습니다.",
"displayMsg": "출발지와 도착지 간의 직선거리가 700m 미만인 경우, 결과를 제공하지 않습니다.",
"start": "349509185,149283507,군포역",
"end": "349507865,149289148,군포중학교",
"pointDistance": "580",
"walkTime": "9",
"viewType": "list"
}
}
# 긴경로를 넣으면 아래정포를 포함한게 나온다.
"info": {
"mapObj": "18929:1:17:23@1142:1:3:17|0:0:0:0@0:0:0:0",
"payment": "1200",
"busTransitCount": "2",
"subwayTransitCount": "0",
"busStationCount": "20",
"subwayStationCount": "0",
"totalStationCount": "20",
"totalTime": "63",
"totalWalk": "1870",
"trafficDistance": "7147",
"totalDistance": "9017",
"firstStartStation": "초평동",
"lastEndStation": "군포중학교",
"totalWalkTime": "29",
"subwayExpress": "0"
}
},
계획
- 위 api 로 원하는 범위내 버스 정류장 습득 (지하철역 인근에 버스정류장은 반드시 있으므로 버스정류장만 알면 충분)
- 길찾기 api를 조합하여 요청, info 를 해석한다.
- 경로에 점수를 매긴다
- totalTime 이 적은게 제일 좋음
- 동률이라면 환승이 적은편으로.. (버스환승이 더 적어야함)
- 그래도 동률이라면 걷는 시간이 적은편으로
- 그래도 동률이라면 비용이 적은 쪽으로 선정
- 이후 동률은 의미 없으니 uuid 오름차순
- api 호출 제한을 넘기면 안 되므로 호출 순번을 정해서 파티션 테이블에 밀어 넣음
- 위와 같은 시스템을 만들기 위해 airflow를 사용
- airflow 와 기타 필요한 환경을 위해 minikube 사용
- minikube 위에 올릴 helm 차트는 가급적 수정 안하는 방식으로 진행. (value만 이용해서... 작업)
주택에 점수 매기는 기준
- 직장 근처를 지나는 버스가 지나가는가?
- 근처에 지하철 역이 있는가?
- 1순위, 2순위 정도는 뽑아야 할 듯
- 환승역이라면 가산점
- 근처에 교육시설이 있는가?
- 유치원 / 어린이집
- 초등학교 / 중학교 / 고등학교
- 근처에 병원이 있는가?
- 직장-집 동선상에 체육 시설이 있는가?
- 주차 공간은 넉넉 한가?
- 남향인가?
- 면적은?
- 몇층인가?
- 예상 출퇴근 시간은 얼마나 되는가?
- 관리비는 얼마 나오는가?
- 거래가 잘되는 지역인가?
- 건물에 걸린 융자는 어떻게 되는가?
- 건물 나이는 어떻게 되는가?
- 대형마트와의 거리는 어떻게 되는가?
- else ?
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.