묻고 답해요
164만명의 커뮤니티!! 함께 토론해봐요.
인프런 TOP Writers
-
미해결파이썬 입문 및 웹 크롤링을 활용한 다양한 자동화 어플리케이션 제작하기
anaconda 가상환경에서 atom실행 관련 문의입니다.
안녕하세요. 저는 현재 mac os x 를 사용 중입니다. anaconda를 설치하고, 가상환경 설치를 완료하였습니다. section2 , test1 , test2 입니다. section2 환경에 접속하여 atom 명령어 사용시 실행이 되지 않아 문제가 생겼으나, UI환경에서 atom을 한 번 실행시킨 후에는 터미널 환경에서 atom 명령어로 실행은 됩니다. 하지만 강의 내용처럼 아나콘다 가상환경인 section 2 환경에서 실행되지 않고, 그냥 일반적으로 untitled로 실행이 되는 것 같아 아나콘다 상에서 atom을 못 찾는 즉, 경로 설정의 문제 인가 싶어 bin_profile 안을 살펴봤으나 경로는 올바르게 설정되어 있는 듯 합니다. 무엇이 문제인지 잘 모르겠습니다. 구글링을 해봐도 window 관련 레퍼런스나 블로그만 많을 뿐, mac에 알맞은 문서나 설명이 나오지 않는 것 같습니다. 조언 부탁드립니다. 감사합니다. #bin_profile # >>> conda initialize >>> # !! Contents within this block are managed by 'conda init' !! __conda_setup="$('/Users/kim/opt/anaconda3/bin/conda' 'shell.bash' 'hook' 2> /dev/null)" if [ $? -eq 0 ]; then eval "$__conda_setup" else if [ -f "/Users/kim/opt/anaconda3/etc/profile.d/conda.sh" ]; then . "/Users/kim/opt/anaconda3/etc/profile.d/conda.sh" else export PATH="/Users/kim/opt/anaconda3/bin:$PATH" fi fi unset __conda_setup # <<< conda initialize <<<
-
미해결레트로의 유니티 C# 게임 프로그래밍 에센스
레벨아트 콜라이더 질문
레벨아트에 대해 궁금한게 있는데보통 콜라이더는 어떤식으로 다나요? mesh collider를 달면 mesh에 따라 자동으로 콜라이더를 그려주니까컴포넌트 추가만 하면 되서 되게 편한데 성능에 좋지않다고 봤습니다.그럼 예를 들어 유니티 스토어에서 마을 팩을 샀다고 했을때건물, 나무, 자동차 등 기타 여러 수많은 오브젝트들이 있을텐데이걸 하나하나 일일히 박스, 캡슐 콜라이더를 달아주고 크기조절까지 해주는건가요?(예를 들어 실내 같은 경우 벽면 마다 박스콜라이더를 쳐서 막는다던지)이게 작은 규모의 마을이면 상관없는데마을 규모가 커지면 달아야하는 콜라이더도 늘어날텐데 전부 직접 해줘야 하는 작업인지아니면 유니티에서 편의성을 제공하는게 있는지 궁금합니다.
-
미해결윤재성의 스프링 프레임워크 개발자를 위한 실습을 통한 입문 과정
constuctor-arg prototype 객체 문의
안녕하세요. 공부하다가 궁금한게 생겼는데요. 밑에 그림처럼 객체를 파라미터로 주면 각각 다른 객체가 주입되는데요. constructor-arg로 정의하면 무조건 다른 객체가 생성되서 넣어지는건가요?? 싱글톤이 아니라 다른 객체가 넣어져서 궁금해서요. 왜냐하면 xml에 scope에 대한 정의를 하지 않았는데 다른객체가 넣어져서 의아하네요!
-
미해결대세는 쿠버네티스 (초급~중급편)
pod 의 immutable 한 field
선생님 안녕하세요! kubectl edit 명령을 사용해서 실행중인 pod 의 (deployment 나 replicaset 은 만들지 않았어용!) resource.limits.memory 값을 수정하려고 하니 실패하더라구요! 메세지를 보니... Normal 0 false false false EN-US KO TH /* Style Definitions */ table.MsoNormalTable {mso-style-name:"표준 표"; mso-tstyle-rowband-size:0; mso-tstyle-colband-size:0; mso-style-noshow:yes; mso-style-priority:99; mso-style-parent:""; mso-padding-alt:0in 5.4pt 0in 5.4pt; mso-para-margin-top:0in; mso-para-margin-right:0in; mso-para-margin-bottom:8.0pt; mso-para-margin-left:0in; text-align:justify; text-justify:inter-ideograph; line-height:107%; mso-pagination:widow-orphan; font-size:10.0pt; font-family:"Malgun Gothic",sans-serif; mso-ascii-font-family:"Malgun Gothic"; mso-ascii-theme-font:minor-latin; mso-fareast-font-family:"Malgun Gothic"; mso-fareast-theme-font:minor-fareast; mso-hansi-font-family:"Malgun Gothic"; mso-hansi-theme-font:minor-latin; mso-font-kerning:1.0pt; mso-fareast-language:KO;} spec.containers[*].image spec.initContainers[*].image spec.activeDeadlineSeconds spec.tolerations 빼고는 수정할 수가 없다고 나오네요 혹시 pod 을 포함하여 kubernetes 오브젝트들의 immutable 한 필드를 알 수 있는 문서가 있을까요? 공식문서에서 검색하고 있는데 발견이 안되네요 ㅎㅎ
-
미해결파이썬 레시피 - 웹 활용 입문편 (전자책 포함)
유튜브 키워드 진행중 막히는것이 있어 질문 드립니다.
안녕하세요 강의 덕에 많은 도움을 받고 있던 와중, 참 골치아픈 상황에 직면하게 되어 처음으로 질문을 남겨봅니다. 크롬을 자동으로 여는 과정까지는 완벽하나, 유튜브 검색창에 자동으로 입력이 되지 않습니다. 문제는 코드를 건드리지 않고 계속 시도(Run) 해보면 가끔 한번씩은 성공합니다. time.sleep 값을 늘려도 보고 줄여도 보고 아무리 해봐도 그냥 랜덤이네요.... 실패 시엔 이렇게 출력됩니다. selenium.common.exceptions.ElementNotInteractableException: Message: element not interactable (Session info: chrome=81.0.4044.92) 크롬과 드라이버 다운그레이드도 해보았고 모두 최신으로도 해봐도 여전하네요. 구글링 해봐도 비슷한 상황이라 골머리 앓으며 질문 남겨봅니다...ㅜ ps. 가끔은 attributeerror: 'Webdriver' object has no attribute 'send_keys' 이런 에러를 출력 받곤 합니다.
-
미해결윤재성의 스프링 프레임워크 개발자를 위한 실습을 통한 입문 과정
생성자 파라미터 순서 getBean 문의
생성자 파라미터 순서에 대해서 강의를 들었는데요. xml에 index값을 하지 않고 똑같은 생성자인데 파라미터 순서만 다른 생성자를 3개 부여 하면 어떤 우선순위로 getBean을 하나요? 이런식으로 하면 "TestBean의 생성자" 가 print되는데요. 만약 중간에 있는 생성자(2번째)를 주석처리하고 실행하면 맨 마지막꺼가 getBean 되더라고요. 이게 어떤 우선순위인지 실행만으로 찾기 힘드네요 ㅠㅠ ----------------------------------------------------- public TestBean(int data1,double data2,String data3) { System.out.println("TestBean의 생성자 : 변수 3개"); this.data1 = data1; this.data2 = data2; this.data3 = data3; } public TestBean(int data1,String data3,double data2) { System.out.println("TestBean2의 생성자 : 변수 3개"); this.data1 = data1; this.data2 = data2; this.data3 = data3; } public TestBean(String data3,int data1,double data2) { System.out.println("TestBean3 생성자 : 변수 3개"); this.data1 = data1; this.data2 = data2; this.data3 = data3; } -------------------------------------------------------------------------------------------
-
미해결Vue.js 끝장내기 - 실무에 필요한 모든 것
에러 처리에 대해서 질문좀..
안녕하세요. 초보개발자입니다.제가 다니고 있는 회사에서는 아직 jsp에cdn으로 vue를 등록해서 사용하고 있어요.(cli버전으로 개발하는 방법을 따로 공부중입니다. )그래서 비동기 통신을 제이쿼리의 ajax를 사용중인데 catch 문에서 에러 처리하는게 ajax에서 error :{}부분에 해당하는건가요?
-
미해결[개정판] 파이썬 머신러닝 완벽 가이드
혹시 사이킷런에서 이런게 될까요?
크게 두가지의 질문이 있습니다. 1. 서비스화 질문 2. 학습한 데이터 저장/로드 질문 3. 추가 학습에 대한 질문 1. 사이킷런을 서비스화를 한다고 하였을 때 파이썬 모듈로 서비스로 올려서 학습까지 진행한뒤에 웹서비스같은 걸 띄워서 피쳐들을 파라미터를 받는 형식으로 해서 예측 결과를 리턴하도록 서비스를 구성해야 하나요? 일반 현업이나 많이 쓰이는 방법이 궁금해서 질문 드립니다. 2. 만약 서비스를 하다가 서비스를 재실행해야 되는 문제나 여러가지 문제가 생길경우 학습한 데이터를 서비스를 올릴때 다시 학습을 진행해야 하나요? 아니면 학습한 메모리 데이터를 따로 저장하는 기능이 있어 다시 실행할 때 다시 로드 후 바로 서비스화 할 수 있나요? 3. 현재 학습한 학습기에다가 추가로 어떠한 데이터들을 추가적으로 학습을 시키고 싶을경우 이 피쳐들을 다시 이전 피쳐들과 합쳐서 다시 학습을 시키는 방법밖에 없을까요? 예를 들어 이전 학습기는 어제까지 데이터를 학습해서 서비스를 하고 하루뒤에 오늘 데이터를 추가해서 학습해야 하는 상황에서 좋은 방법이 있을까요? 이런 기술들이 현업에서 사용될 니즈가 있는 기술인데 생각하다 궁급해서 질문 남김니다!!
-
미해결따라하며 배우는 노드, 리액트 시리즈 - 챗봇 사이트 만들기
환경 변수 설정 문제
UnhandledPromiseRejectionWarning: Error: Could not load the default credentials. 환경 변수 설정 후에는 정상 작동하지만 vscode를 껐다 키면 환경 변수를 다시 설정해줘야하는데 저의 문제인가요?
-
미해결파이썬 무료 강의 (기본편) - 6시간 뒤면 나도 개발자
1분대 첫 계산당시 6/3은 왜 2가 아닌 2.0으로 출력이 되는건가요?
궁금합니다. 단순 나눗셈이라 저렇게 나오는건지요
-
미해결프로그래밍 시작하기 : 파이썬 입문 (Inflearn Original)
"Unable to verify the first certificate" 오류 관련
계정명 영문명이고 관리자 권한 실행 apm config set strict-ssl false 다 아무 소용 없네요 (apm을 기존 답변에 나와있는 bin 폴더까지 들어가서 실행할 필요도 없는 것 같구요 - 윈도우10 기준) apm install autocomplete-python 으로 일단 설치했습니다 강의 본게 30분 남짓인 것 같은데 이거 찾느라 30분 이상 낭비한게 시작부터 너무 짜증나고 같은 질문이 반복되었는데 제대로 답변이 된 것도 없고 초보자용 강의에서 왜 굳이 설정이 까다로운 atom으로 강의가 진행되어야 하는지도 모르겠습니다 시작부터 별로네요
-
미해결남박사의 파이썬으로 실전 웹사이트 만들기
로컬서버에서 코드 작성한게 반영이 안되고 있습니다.
강의 내용 중, 구글 클라우드 플랫폼을 이용한 방법으로 웹사이트를 구현중에 있는데요, 참 이상하게도 웹서버에서는 정상적으로 제가 구현한 사이트가 정상 작동이 되는데, 로컬서버에서는 제가 수정한 코드들이 제대로 반영이 안되고 있습니다. svg, css 적용이 제대로 안되고 그림표시로 나오더라구요. 혹시 몰라서 컴퓨터 재시작도 해보고, 크롬 브라우저의 캐시 삭제도 여러번 시도 해봤지만 로컬환경에서 수정사항들이 전혀 반영이 되지 않고 있는 상황인데요... 하나 해결하면 또다른 문제가 계속 생기네요.. ㅎㅎ;; 남박사님, 혹시 이런경우는 어떻게 해결을 해야 하는지 너무 궁금합니다.
-
미해결트렐로 개발로 배우는 Vuejs, Vuex, Vue-Router 프론트엔드 실전 기술
노드 api 서버 npm install 시 발생하는 에러
gyp ERR! find Python gyp ERR! find Python Python is not set from command line or npm configuration gyp ERR! find Python Python is not set from environment variable PYTHON gyp ERR! find Python checking if "python" can be used gyp ERR! find Python - "python" is not in PATH or produced an error gyp ERR! find Python checking if "python2" can be used gyp ERR! find Python - "python2" is not in PATH or produced an error gyp ERR! find Python checking if "python3" can be used gyp ERR! find Python - "python3" is not in PATH or produced an error gypgyp ERR! find PythonERR! checking if the py launcher can be used to find Python 2 gypfind Python ERR! gypfind Python - "py.exe" is not in PATH or produced an error ERR!gyp find PythonERR! Python is not set from command line or npm configuration find Pythongyp checking if Python is C:\Python27\python.exe ERR!gyp find Python Python is not set from environment variable PYTHON ERR!gyp find Python - "C:\Python27\python.exe" could not be run ERR!gyp find Python checking if "python" can be used ERR! gypfind Python checking if Python is C:\Python37\python.exe gypERR! ERR! find Pythonfind Python - "C:\Python37\python.exe" could not be run - "python" is not in PATH or produced an error gypgyp ERR!ERR! find Pythonfind Python checking if "python2" can be used gyp gypERR! ERR!find Python ********************************************************** find Pythongyp - "python2" is not in PATH or produced an error gypERR! ERR!find Python You need to install the latest version of Python. gypfind Python checking if "python3" can be used ERR!gyp find PythonERR! Node-gyp should be able to find and use Python. If not, gyp find PythonERR! - "python3" is not in PATH or produced an error gypfind Python you can try one of the following options: gypERR! ERR!find Python checking if the py launcher can be used to find Python 2 find Pythongyp - Use the switch --python="C:\Path\To\python.exe" ERR!gyp find Python - "py.exe" is not in PATH or produced an error ERR!gyp ERR!find Python (accepted by both node-gyp and npm) find Python checking if Python is C:\Python27\python.exe gyp gypERR! ERR! find Pythonfind Python - Set the environment variable PYTHON - "C:\Python27\python.exe" could not be run gypgyp ERR!ERR! find Pythonfind Python - Set the npm configuration variable python: checking if Python is C:\Python37\python.exe gyp gypERR! find PythonERR! npm config set python "C:\Path\To\python.exe" gypfind Python - "C:\Python37\python.exe" could not be run gypERR! find PythonERR! For more information consult the documentation at: find Pythongyp gypERR! ERR!find Python https://github.com/nodejs/node-gyp#installation find Pythongyp ********************************************************** gypERR! ERR!find Python find Python ********************************************************** You need to install the latest version of Python. gypgyp ERR! find PythonERR! Node-gyp should be able to find and use Python. If not, gypfind Python ERR! find Python you can try one of the following options: gypgyp ERR!ERR! find Pythonconfigure error - Use the switch --python="C:\Path\To\python.exe" gypgyp ERR!ERR! stackfind Python Error: Could not find any Python installation to use (accepted by both node-gyp and npm) gypgyp ERR!ERR! find Pythonstack - Set the environment variable PYTHON at PythonFinder.fail (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\find-python.js:307:47) gypgyp ERR! ERR!find Python - Set the npm configuration variable python: gypstack ERR! at PythonFinder.runChecks (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\find-python.js:136:21) gyp find Python npm config set python "C:\Path\To\python.exe" ERR! gypstack at PythonFinder.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\find-python.js:225:16) ERR!gyp find Python For more information consult the documentation at: ERR!gyp stackERR! at PythonFinder.execFileCallback (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\find-python.js:271:16) gypfind Python https://github.com/nodejs/node-gyp#installation ERR!gyp ERR!stack find Python at exithandler (child_process.js:310:5) ********************************************************** gypgyp ERR!ERR! stackfind Python at ChildProcess.errorhandler (child_process.js:322:5) gyp ERR!gyp stackERR! at ChildProcess.emit (events.js:311:20) gypconfigure error ERR! gypstack at Process.ChildProcess._handle.onexit (internal/child_process.js:273:12) ERR!gyp stackERR! Error: Could not find any Python installation to use gypstack at onErrorNT (internal/child_process.js:469:16) ERR!gyp stackERR! at PythonFinder.fail (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\find-python.js:307:47) gypstack at processTicksAndRejections (internal/process/task_queues.js:84:21) ERR! stackgyp at PythonFinder.runChecks (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\find-python.js:136:21) gypERR! ERR!System Windows_NT 10.0.17763 stackgyp at PythonFinder.<anonymous> (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\find-python.js:225:16) gypERR! ERR!command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "configure" "--fallback-to-build" "--module=C:\\Users\\LG\\WebstormProjects\\lecture-vue-trello-server\\node_module s\\sqlite3\\lib\\binding\\node-v72-win32-x64\\node_sqlite3.node" "--module_name=node_sqlite3" "--module_path=C:\\Users\\LG\\WebstormProjects\\lecture-vue-trello-server\\node_modules\\sqlite3\\lib\\binding\\node-v72-win32-x64" "--napi_version=5" "--node_abi_napi=nap i" stack at PythonFinder.execFileCallback (C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\lib\find-python.js:271:16) gyp gypERR! ERR! cwdstack C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modules\sqlite3 at exithandler (child_process.js:310:5) gypgyp ERR!ERR! stack at ChildProcess.errorhandler (child_process.js:322:5) node -vgyp v12.16.1 ERR!gyp ERR!stack at ChildProcess.emit (events.js:311:20) node-gyp -vgyp v5.0.5 ERR!gyp stackERR! at Process.ChildProcess._handle.onexit (internal/child_process.js:273:12) gyp not okERR! stack at onErrorNT (internal/child_process.js:469:16) gyp ERR! stack at processTicksAndRejections (internal/process/task_queues.js:84:21) gyp ERR! System Windows_NT 10.0.17763 gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Program Files\\nodejs\\node_modules\\npm\\node_modules\\node-gyp\\bin\\node-gyp.js" "configure" "--fallback-to-build" "--module=C:\\Users\\LG\\WebstormProjects\\lecture-vue-trello-server\\node_modules\\sql ite3\\lib\\binding\\node-v72-win32-x64\\node_sqlite3.node" "--module_name=node_sqlite3" "--module_path=C:\\Users\\LG\\WebstormProjects\\lecture-vue-trello-server\\node_modules\\sqlite3\\lib\\binding\\node-v72-win32-x64" "--napi_version=5" "--node_abi_napi=napi" gyp ERR! cwd C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modules\sqlite3 gyp ERR! node -v v12.16.1 gyp ERR! node-gyp -v v5.0.5 gypnode-pre-gyp ERR!ERR! build errornot ok node-pre-gyp ERR! stack Error: Failed to execute 'C:\Program Files\nodejs\node.exe C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modu les\sqlite3\lib\binding\node-v72-win32-x64\node_sqlite3.node --module_name=node_sqlite3 --module_path=C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modules\sqlite3\lib\binding\node-v72-win32-x64 --napi_version=5 --node_abi_napi=napi' (1) node-pre-gyp ERR! stack at ChildProcess.<anonymous> (C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modules\node-pre-gyp\lib\util\compile.js:83:29) node-pre-gyp ERR! stack at ChildProcess.emit (events.js:311:20) node-pre-gyp ERR! stack at maybeClose (internal/child_process.js:1021:16) node-pre-gyp ERR! stack at Process.ChildProcess._handle.onexit (internal/child_process.js:286:5) node-pre-gyp ERR! System Windows_NT 10.0.17763 node-pre-gyp ERR! command "C:\\Program Files\\nodejs\\node.exe" "C:\\Users\\LG\\WebstormProjects\\lecture-vue-trello-server\\node_modules\\node-pre-gyp\\bin\\node-pre-gyp" "install" "--fallback-to-build" node-pre-gyp ERR! cwd C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modules\sqlite3 node-pre-gyp ERR! node -v v12.16.1 node-pre-gyp ERR! node-pre-gyp -v v0.10.3 node-pre-gyp ERR! not ok Failed to execute 'C:\Program Files\nodejs\node.exe C:\Program Files\nodejs\node_modules\npm\node_modules\node-gyp\bin\node-gyp.js configure --fallback-to-build --module=C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modules\sqlite3\lib\binding\node-v7 2-win32-x64\node_sqlite3.node --module_name=node_sqlite3 --module_path=C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modules\sqlite3\lib\binding\node-v72-win32-x64 --napi_version=5 --node_abi_napi=napi' (1) npm WARN rollback Rolling back safe-buffer@5.1.2 failed (this is probably harmless): EPERM: operation not permitted, rmdir 'C:\Users\LG\WebstormProjects\lecture-vue-trello-server\node_modules\minipass\node_modules' npm WARN lecture-vue-trello-server@1.0.0 No description npm WARN lecture-vue-trello-server@1.0.0 No repository field. npm WARN optional SKIPPING OPTIONAL DEPENDENCY: fsevents@1.2.4 (node_modules\fsevents): npm WARN notsup SKIPPING OPTIONAL DEPENDENCY: Unsupported platform for fsevents@1.2.4: wanted {"os":"darwin","arch":"any"} (current: {"os":"win32","arch":"x64"}) npm ERR! code ELIFECYCLE npm ERR! errno 1 npm ERR! sqlite3@4.0.2 install: `node-pre-gyp install --fallback-to-build` npm ERR! Exit status 1 npm ERR! npm ERR! Failed at the sqlite3@4.0.2 install script. npm ERR! This is probably not a problem with npm. There is likely additional logging output above. npm ERR! A complete log of this run can be found in: npm ERR! C:\Users\LG\AppData\Roaming\npm-cache\_logs\2020-04-11T16_23_05_051Z-debug.log 무슨오류인가요..? sqlite3, python 둘다 설치했는데도 에러가 납니다 ㅠㅠ 강의에는 아무 설명도 없고 답답해서 질문올려요
-
미해결파이썬 알고리즘 문제풀이 입문(코딩테스트 대비)
열의 합, 행의 합을 구할 때
격자판 최대합 영상에서와 같이 가로와 세로가 n x n으로 같을 때, 열과 행의 합을 구할 때는 for i in range(n): 열 = 행 = 0 for j in range(n): 열 += a[i][j] 행 += a[j][i] print(열, 행) 과 같이 코드를 간단하게 할 수 있었습니다. 이 영상만 보고 '아, 앞으로도 열과 행을 합칠 때는 i와 j 자리만 바꿔주면 되겠구나!' 라고 생각했고 이후의 예제에서 적용해보았는데 그렇지 않았습니다. 예를 들어서 n x n 격자판이 아닌, 7 x 3 격자판이라 가정하겠습니다. 나눠진 부분에서의 각 열의 합, 행의 합을 구하려고 합니다. 이번 영상에서 한 것처럼 코드를 만들었지만, for i in range(3): 열 = 행 = 0 for j in range(4, 7): 열 += a[i][j] 행 += a[j][i] print(열, 행) IndexError가 나면서 오류가 발생했습니다. 고민해보다가 단순히 자리만 바꾸는건 안되겠다 싶어서 코드를 이렇게 바꿨습니다. for i in range(3): 열 = 0 for j in range(4, 7): 열 += a[i][j] print(열) for j in range(4, 7): 행 = 0 for i in range(3): 행 += a[i][j] print(행) 이렇게 바꿨더니 실행은 되었지만, 코드가 2배로 길어졌습니다. 혹시 이렇게 코드를 2배로 적지 않고 for 구문 2개 1번으로만 간단하게 적는 방법이 있습니까?
-
미해결누구나 따라하면서 배우는 JSP 커뮤니티 게시판 만들기
이클립스에서 jsp 문법 오류를 발견할 수 없는데..
이클립스에서 jsp 문법 오류를 발견할 수 없는데.. (몇번을 검토해도 똑같은데 대체 어디가 틀린지 알 수 없습니다..) 혹시 해당 코드 올라와 있는 github 주소 있을까요?
-
해결됨웹 게임을 만들며 배우는 자바스크립트
[ 숫자야구 ] 답변할때마다 기회 몇번 남았는지 표시 관련 질문 드려요
쌤.. 답변할때마다 기회 몇번 남았는지 표시 하는거 힌트 없을까요.. 이미 힌트 주신거 아는데...그래두 잘 모르겠어요... if 구문을 뭐로 해야 할지...순서를 어디에 배치해야 될까요 1 / 입력창 답 칠때마다 2 / '기회 ~번 남음' 텍스트 나오고 3 / 3회 반복후 4 / 다시 처음으로 돌아감. 이렇게 생각중인데요.. 코드로는....ㅠㅠ....; if (답 !== 입력창) { this.textContent = "기회 번 남음"; }
-
미해결파이썬 알고리즘 문제풀이 입문(코딩테스트 대비)
2차원 리스트에서 이해가 되지 않는 부분이 있습니다.
제가 Section 3에서 격자판 회문수까지 동영상을 보고 있던 도중에, 문득 이해가 되지 않는 부분이 생겼습니다. 2차원 리스트의 개념을 볼 때, list[i][j]의 행태로 각각의 요소값들을 추출할수 있습니다. 예를 들어서 a라는 이름의 리스트가 있다고 할 때 a = [[1,2,3], [4, 5, 6], [7, 8, 9]]를 for x in a: print(x)로 결과를 보면 의 형태가 되면서, 꼭 x와 y를 쓰는 함수의 형태와 비슷해지는데 여기서 a[1][2]의 값은 6입니다.즉 i는 몇 번째 줄인지를 나타내고 j는 줄 i에서 몇번째로 오른쪽에 있는 값을 나타내는 것임으로써 저는 항상 i는 함수에서의 y값(세로), j는 함수에서의 x값(가로)과 비슷하게 생각했었는데 동영상을 보면서 확인을 해보니 교수님이 설명을 해주실때는 i와 j가 아래와 같이 반대인 것처럼 보였습니다. 마치 이런 느낌이어서 어떻게 이해를 해야 하나 싶습니다. 이렇게 보면 a[1][1]값과 a[1][2]값을 비교하면 j가 달라지는데 실제로 5와 6은 바로 옆에 있어서 제 생각으로는 j가 위아래 델타값이 아닌 좌우 델타값이 되어야 한다고 생각했습니다. 2차원 리스트에 관한 내용중 대부분 설명을 제가 생각했던거와는 달랐는데, 코드를 좀 난잡하게 짜서 교수님은 어떻게 간단하게 하셨을까 하면서 영상을 보면 항상 더 머리가 복잡해 지는것 같습니다. 제가 이차원 리스트를 너무 함수그래프처럼 생각해서 이해가 잘 되지 않는 것일까요? 어떤 방법으로 이걸 이해해야 할지 감이 잘 잡히지 않습니다..
-
미해결[개정판] 딥러닝 컴퓨터 비전 완벽 가이드
안녕하세요 강사님 Faster RCNN 부분 질문 있습니다.
강의는 RCNN 계열 object Dtecter(...) - Faster RCNN의 이해 01 - RPN(...)과 Anchor Box 입니다. 강의 13:04초 쯤에 나오는 크기가 1/16으로 서브샘플링이 된다고 한다면 피쳐맵이 60 40 이되고 채널이 512 된다는 뜻이 잘 이해가 가질 않습니다. 첫번쨰 질문입니다. 서브샘플링이 동영상의 데이터 크기를 줄이기 위한 방법이라고 하던데 이 계산이 어떻게 되는지 알 수 있을까요?? 그리고 채널이 색을 말씀하시는건가요?? 저는 색이라고 생각을 했는데 512로 되어있다고 해서 이 부분도 잘 이해가 가질 않습니다.. 두번째 질문입니다. Faster RCNN의 이해 03 - RPN과 Faster RCNN Training 및 성능 비교 강의 10분 27초입니다. Fine Tuning을 해서 convolutional network에 가중치를 수정하지 않는다고 하셨는데 그러면 regional proposal network에 의하여 학습된 convolutional network는 사용하지 않으니 classes와 boundary box로 학습된 convolutional network 가중치만을 사용하는 것인가요?? 이 부분에 대해서 답변해주시면 감사하겠습니다! 감사합니다.
-
미해결남박사의 파이썬 기초부터 실전 100% 활용
while 반복문 실행순서 문의
pos = 0 while True: if pos+1 > len(list): break if list[pos] in operator: temp = list[pos-1] + list[pos] + list[pos+1] #print('temp',temp) del list[0:3] #print('del',list) list.insert(0,str(eval(temp))) #print('list',list) pos = 0 pos += 1 위 예제가 while 반복문은 세개 문단(?)으로 되어 있다고 한다면, 1) 1번 조건 확인 -> 2번조건 만족할때까지 계속반복 -> 3번 pos +=1 -> 1번조건 확인 반복순서인가요? 아니면 2) 1번 조건 확인 -> 2번조건 첫번째수행 -> 3번 pos +=1 수행 -> 1번 조건 확인 -> 2번조건 두번째수행 -> 3번 pos +=1 번 -> 다될때까지 반복 인가요? 2번 논리로 실행된다고 하면 2번째 문단 끝이 pos =0이고 3번째 시작이 pos +=1을 해주는게 이해가 안되서 1)로 작동하는거 같은데, 확실치 않아서 문의드립니다. 감사합니다.
-
미해결홍정모의 따라하며 배우는 C++
소멸자 관련 질문드립니다.
강의: 8.6 소멸자 destructor / 약 8분30초 안녕하세요. 매번 강의를 잘 보고 있습니다. 강의를 보던 중, my_int_arr(1000)의 소멸자가 언제 호출되는지 궁금하여 질문드립니다. my_int_arr가 while문 영역을 벗어나면서 사라지려고 할 때 소멸자가 호출되서 delete이 된다고 하셨는데요, while의 조건문이 true이기 때문에 my_int_arr가 항상 while문 영역 내에 있는게 아닌지 궁금합니다. my_int_arr가 계속 while문 영역에 있으므로 소멸자가 호출되지 않을 것 같은데 실제로 delete이 되는걸 보니 제가 잘못알고 있는 부분이 있는 것 같습니다. while문의 바디를 다 처리하고, while 조건문의 참/거짓을 판단할 때 while문 영역을 벗어난 거라고 봐야하나요?