inflearn logo
강의

강의

N
챌린지

챌린지

멘토링

멘토링

N
클립

클립

로드맵

로드맵

지식공유

묻고 답해요

172만명의 커뮤니티!! 함께 토론해봐요.

colors[theme]을 못읽는 이유

해결됨

맛집 지도앱 만들기 (React Native & NestJS)

import React, {ReactNode} from 'react'; import { Pressable, StyleSheet, Text, PressableProps, Dimensions, View, StyleProp, ViewStyle, TextStyle, } from 'react-native'; import {colors} from '../../constants'; import useThemeStore from '@/store/useThemeStore'; import {ThemeMode} from '@/types/common'; interface CustomButtonProps extends PressableProps { label: string; variant?: 'filled' | 'outlined'; size?: 'large' | 'medium'; inValid?: boolean; style?: StyleProp<ViewStyle>; textStyle?: StyleProp<TextStyle>; icon?: ReactNode; } const deviceHeight = Dimensions.get('screen').height; function CustomButton({ label, variant = 'filled', size = 'large', inValid = false, style = null, textStyle = null, icon = null, ...props }: CustomButtonProps) { const {theme} = useThemeStore(); const styles = styling(theme); // 여기서는 제대로 출력이 됩니다. 값이 제대로 읽힙니다. console.log(colors[theme].PINK_700); return ( <Pressable disabled={inValid} style={({pressed}) => [ styles.container, pressed ? styles[`${variant}Pressed`] : styles[variant], inValid && styles.inValid, style, ]} {...props}> <View style={styles[size]}> {icon} <Text style={[styles.text, styles[`${variant}Text`], textStyle]}> {label} </Text> </View> </Pressable> ); } const styling = (theme: ThemeMode) => StyleSheet.create({ container: { borderRadius: 3, justifyContent: 'center', flexDirection: 'row', }, inValid: { opacity: 0.5, }, filled: { backgroundColor: colors[theme].PINK_700, }, outlined: { borderColor: colors[theme].PINK_700, borderWidth: 1, }, filledPressed: { backgroundColor: colors[theme].PINK_500, }, outlinedPressed: { borderColor: colors[theme].PINK_700, borderWidth: 1, opacity: 0.5, }, large: { width: '100%', paddingVertical: deviceHeight > 700 ? 15 : 10, alignItems: 'center', justifyContent: 'center', flexDirection: 'row', gap: 5, }, medium: { width: '50%', paddingVertical: deviceHeight > 700 ? 12 : 8, alignItems: 'center', justifyContent: 'center', flexDirection: 'row', gap: 5, }, text: { fontSize: 16, fontWeight: '700', }, filledText: { color: colors[theme].WHITE, }, outlinedText: { color: colors[theme].PINK_700, }, }); export default CustomButton; console.log(colors[theme].PINK_700); 이렇게 출력할 경우, 제대로 아래와 같이 출력이 됩니다만 스타일은 제대로 읽어오지 않습니다. 이 부분에 대해서 알고 싶습니다. BUNDLE ./index.js LOG Running "MatzipApp" with {"rootTag":171,"initialProps":{"concurrentRoot":false}} LOG light LOG #C63B64 LOG #C63B64 LOG #C63B64 ERROR TypeError: Cannot read property 'PINK_700' of undefined This error is located at: in CustomButton (created by ErrorBoundary) in RCTView (created by View) in View (created by ErrorBoundary) in ErrorBoundary (created by RetryErrorBoundary) in RetryErrorBoundary (created by RootNavigator) in RootNavigator (created by App) in EnsureSingleNavigator in BaseNavigationContainer in ThemeProvider in NavigationContainerInner (created by App) in _QueryClientProvider (created by App) in App in RCTView (created by View) in View (created by AppContainer) in RCTView (created by View) in View (created by AppContainer) in AppContainer in MatzipApp(RootComponent), js engine: hermes ERROR TypeError: Cannot read property 'WHITE' of undefined This error is located at: in RetryErrorBoundary (created by RootNavigator) in RootNavigator (created by App) in EnsureSingleNavigator in BaseNavigationContainer in ThemeProvider in NavigationContainerInner (created by App) in _QueryClientProvider (created by App) in App in RCTView (created by View) in View (created by AppContainer) in RCTView (created by View) in View (created by AppContainer) in AppContainer in MatzipApp(RootComponent), js engine: hermes ERROR TypeError: Cannot read property 'WHITE' of undefined This error is located at: in RetryErrorBoundary (created by RootNavigator) in RootNavigator (created by App) in EnsureSingleNavigator in BaseNavigationContainer in ThemeProvider in NavigationContainerInner (created by App) in _QueryClientProvider (created by App) in App in RCTView (created by View) in View (created by AppContainer) in RCTView (created by View) in View (created by AppContainer) in AppContainer in MatzipApp(RootComponent), js engine: hermes ERROR TypeError: Cannot read property 'WHITE' of undefined https://github.com/dydals3440/MatZip 좀더 정확히 판단을 위하여 제가 커밋한 레포 남겨드립니다!!!

  • react-native
  • typescript
  • nestjs
  • react-query
  • zustand
김용민 댓글 2 좋아요 0 조회수 324

선생님거랑 데이터가 다른데요ㅜ.ㅜ

해결됨

[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)

수업자료에 있는거 다운로드해서 자료 생성했는데 loc2001 찍었을때 결과가 달라요 ㅠ

  • python
  • 머신러닝
  • 빅데이터
  • pandas
  • 빅데이터분석기사
moonwrd 댓글 2 좋아요 0 조회수 326

제출버튼이 없어요

해결됨

[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)

학습 관련 질문을 남겨주세요. 상세히 작성하면 더 좋아요! 질문과 관련된 영상 위치를 알려주면 더 빠르게 답변할 수 있어요 먼저 유사한 질문이 있었는지 검색해보세요 제출아이콘이 없어요

  • python
  • 머신러닝
  • 빅데이터
  • pandas
  • 빅데이터분석기사
csms9870 댓글 1 좋아요 0 조회수 231

우선 1090 모이기 문제를 완전 탐색으로 해보려고 하는데...

해결됨

2주만에 통과하는 알고리즘 코딩테스트 (2024년)

N=4 일 때 좌표 4개가 주어지고 1명, 2명, 3명, 4명 모였을 때의 경우의 수를 비교해야할 것 같은데 1명 모였을때 경우의 수, 2명 모였을 때 경우의 수, 3명 모였을 때 경우의 수, 4명 모였을 때 경우의 수를 어떻게 그 좌표 조합을 만들 수 있는지 고민입니다. 1명 모였을 때는 단일 반복문, 2명일 때 2중 반복문, 3명일 때 3중 반복문이 필요할 것 같은데... 이게 N개면 N개의 반복문을 만드는게 맞나 싶어서요.. ㅠ

  • python
  • 코딩-테스트
  • 알고리즘
현자타임 댓글 2 좋아요 1 조회수 408

기출 3회 작업형 2 수치형/범주형 분리

해결됨

[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)

기출 3회 작업형 2에서 피처엔지니어링 전 df.select _dtypes(exclude = "o").copy() .... 로 트레인 데이터와 테스트 데이터를 수치와 범주형으로 나눈 후 수치형 MinMaxScaler 범주형 원핫인코딩으로 각각 피처링을 하셨는데 이때 수치형을 보면 cols = ["A", "B"...]로 오브젝트형을 지정하셨더라구요. 피처엔지니어링때 cols =[ ] 를 별도 지정하더라도 위 데이터를 나누는 과정이 필수일까요?? 아래처럼 해도 되면 concat도 필요없을거 같아서요. 예) df.select _dtypes(exclude = "o").copy() << 이과정없이 from sklearn.preprocessing import MinMaxScaler scaler = MinMaxScaler() cols = ['Age', 'FamilyMembers'] train[cols] = scaler.fit _transform(train[cols]) test[cols] = scaler. transform(test[cols]) from sklearn.preprocessing import LabelEncoder cols = ['Nationality'] for col in cols: le = LabelEncoder() train[col] = le.fit _transform(train[col]) test[col] = le.transfrom(test[col])

  • python
  • 머신러닝
  • 빅데이터
  • pandas
  • 빅데이터분석기사
92200607 댓글 2 좋아요 1 조회수 161

brew로 mysql 설치 후 서버 실행할 때, 터미널에서 anaconda bin 참조하는 문제

미해결

[리뉴얼] 처음하는 파이썬 백엔드와 웹기술 입문 (파이썬 중급, flask[플라스크] 로 이해하는 백엔드 및 웹기술 기본) [풀스택 Part1-1]

터미널에서 conda activate가 되어 있는 경우에는 conda 설치 위치의 bin을 참조하게 되더라구요. 그래서 강의를 따라서 설치 후 서버를 실행하면 /USERS/{유저}/opt/ananconda3/~~ 를 계속 참조해서 오류가 발생합니다. 이런 경우엔 conda 가상환경을 꺼주시면 정상적으로 동작합니다. conda deactivate mysql.server start

  • python
  • rest-api
  • flask
mins 댓글 2 좋아요 0 조회수 726

작업형 2 베이스라인/라벨인코딩/원핫인코딩 질문

해결됨

[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)

강의를 보니 베이스라인의 경우 object칼럼을 날리고 수치형으로만 했음에도 정확도가 높은 결과가 나왔습니다그런데 실제 시험에서도 저렇게 임의로 칼럼을 날리면서 진행해도 큰 문제가 없을까요?

  • python
  • 머신러닝
  • 빅데이터
  • pandas
  • 빅데이터분석기사
빅분기가자 댓글 2 좋아요 0 조회수 316

passlib 비활성화 해결방법

미해결

처음하는 파이썬 백엔드 FastAPI 입문 (FastAPI부터 비동기 SQLAlchemy까지) [풀스택 Part1-2]

안녕하세요 passlib dp 노랑 불이 들어왔는데, 어떻게 해결하나요? 구글링 해도 안나오네요 ㅠㅠ

  • python
  • mvc
  • sqlalchemy
  • FastAPI
  • backend
noortwrk 댓글 2 좋아요 0 조회수 265

섹션 10. 예시문제 작업형3(신 버전) 강의 질문있습니다!

해결됨

[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)

선생님! 6:05초에 logit("종속변수 ~ 독립변수 + " ) 넣어줄때요, 종속변수는 문제에서 생존여부(Survived)를 예측하고자 한다고 했기때문에 종속변수가 되는걸까요? 아니면 문제 1번에서 Gender 와 Survived 간의 독립성 검정을 한다고 했을때 문제 2번에 Gender가 독립변수인게 적혀있기 때문에 Survived 는 자동으로 종속변수가 되는걸까요? 종속변수를 어떻게 확인해야 하는지 잘 모르겠습니다!

  • python
  • 머신러닝
  • 빅데이터
  • pandas
  • 빅데이터분석기사
김응룡 댓글 1 좋아요 0 조회수 199

typer 호환 문제

미해결

입문자를 위한 LangChain 기초 — v1.0+ 업데이트

마지막 RAG 강의에서, 첫번째 명령문을 실행시키면, !pip install -q langchain langchain-openai tiktoken chromadb typer 호환과 관련된 에러가 발생합니다. ===================== ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts. spacy 3.7.4 requires typer<0.10.0,>=0.3.0, but you have typer 0.12.3 which is incompatible. weasel 0.3.4 requires typer<0.10.0,>=0.3.0, but you have typer 0.12.3 which is incompatible. ===================== ChatGPT를 통하여 여러 해결방안을 제시받아 시도해 보았는데 해결이 되지 않습니다. 손쉬운 해결 방법이 있을지요?

  • python
  • llm
  • langchain
  • openai-api
.Piao. 댓글 2 좋아요 0 조회수 619

jinja2templates

미해결

파이썬 동시성 프로그래밍 : 데이터 수집부터 웹 개발까지 (feat. FastAPI, async, await)

수업대로 127.0.0.1:8000/items/{id} 를 넣었는데 starlette.routing.NoMatchFound: No route exists for name "static" and params "path". internal Server Error 가 나옵니다 ㅠ BASE_DIR, directory 모두 수업대로 다 입력했습니다. 구글링을 해도 방법을 찾질 못해서요.

  • python
  • 동시성
  • FastAPI
  • jinja2
그린 이들 댓글 1 좋아요 0 조회수 262

AWS S3 : 버킷에 사진이 업로드가 안됩니다(2)

해결됨

맛집 지도앱 만들기 (React Native & NestJS)

[Nest] 27666 - 2024. 05. 23. 오후 12:23:25 ERROR [ExceptionsHandler] ENOENT: no such file or directory, stat '/Users/제이름/MatzipApp/server/uploads/index.html'Error: ENOENT: no such file or directory, stat '/Users/제이름/MatzipApp/server/uploads/index.html' 아까 올린 문제는 제가 지역을 잘못봐서 .env 파일에서 수정해서 해결했습니다. 다시 실행해보니 이번엔 저런 오류가 뜨는데욥실제로 저런 디렉토리랑 파일이 서버 하위에 없긴 합니다.. 구글링해도 도저히 답이 안나와서 다시 한번 질문 드립니다!

  • react-native
  • typescript
  • nestjs
  • react-query
  • zustand
Lee rimi 댓글 1 좋아요 0 조회수 358

이번 실기셤 까지 듣고 싶어요.

해결됨

[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)

안녕하세요~! 수강기간이 얼마 안남았네요. 이번 실기시험까지는... 강의 연장 가능할까요?

  • python
  • 머신러닝
  • 빅데이터
  • pandas
  • 빅데이터분석기사
댓글 1 좋아요 0 조회수 332

S3 실행시 버킷에 사진이 업로드가 안됩니다

해결됨

맛집 지도앱 만들기 (React Native & NestJS)

기존에 있는 문제는 해결됐습니다! (개인정보가 있어서 삭제합니다ㅜㅜ)

  • react-native
  • typescript
  • nestjs
  • react-query
  • zustand
Lee rimi 댓글 1 좋아요 0 조회수 221

회원가입 오류입니다!

해결됨

맛집 지도앱 만들기 (React Native & NestJS)

일단 회원가입시 400 에러가 발생 합니다 ! 리퀘스트 인터셉터 에러 내용 {"adapter": ["xhr", "http", "fetch"], "baseURL": "http://localhost:3030", "data": {"email": "ajrfysd@naver.com", "password": "gsas22sgda"}, "env": {"Blob": [Function Blob], "FormData": [Function FormData]}, "headers": {"Accept": "application/json, text/plain, */*"}, "maxBodyLength": -1, "maxContentLength": -1, "method": "post", "timeout": 0, "transformRequest": [[Function transformRequest]], "transformResponse": [[Function transformResponse]], "transitional": {"clarifyTimeoutError": false, "forcedJSONParsing": true, "silentJSONParsing": true}, "url": "/auth/signup", "validateStatus": [Function validateStatus], "withCredentials": true, "xsrfCookieName": "XSRF-TOKEN", "xsrfHeaderName": "X-XSRF-TOKEN"} 리스폰스 인터셉터 [AxiosError: Request failed with status code 400] email, password로그도 잘 찍히고 하는데 왜 400이 발생하는지 모르겠습니다..ㅠㅠ 서버쪽 같기도 한데 잘 모르겠네요.. postgresql에 테이블도 잘 생성 되어 있고 npm run start:dev Application] Nest application successfully started +2ms http://localhost:3030 크롬에서 3030 으로 요청시 로그에 내줄 index.html 없다고 하는거 보니 작동 하는것 같긴 한데... 이상하게 Postman 에서는 couldnot send 나오고... /auth/signup도 마찬가지고... 다른 부분은 confirmPassword를 제가 rePassword로 바꾸었는데 보내는 쪽에서도 비밀번호확인은 안보내는것 같고 받는 쪽에서도 아예 안받는것 같은데.. 혹시 위 내용으로 추측 가능한 부분이 있을까요??

  • react-native
  • typescript
  • nestjs
  • react-query
  • zustand
ajrfyd 댓글 4 좋아요 0 조회수 687

for,while 문

해결됨

코딩테스트 [ ALL IN ONE ]

제가 알기로는 for, while문 모두 반복문인데 왜 O(n)으로 계산되는건가요?

  • python
  • 코딩-테스트
  • 알고리즘
김옥윤 댓글 2 좋아요 1 조회수 331

로그인/회원가입 오류 질문 드립니다.

해결됨

맛집 지도앱 만들기 (React Native & NestJS)

const postLogin = async ({ email, password, }: RequestUser): Promise<ResponseToken> => { console.log('postLogin'); const {data} = await axiosInstance.post('/auth/signin', {email, password}); console.log('data', data); return data; }; 회원가입에서 오류가 발생해서 db를 봤는데 db에 데이터는 들어가 있습니다. 그래서 로그인을 진행해 봤는데 로그인이 되질 않아 postLogin에 console을 찍어 보았더니 axios post 에서 아무런 값도 받아오질 못하고 있었습니다. 오류 코드는 뜨지 않구요. 시뮬레이터를 껏다 켜보기도 하고 서버를 껏다 켜보기도 했는데 이제는 회원가입 시 db에 저장도 되질 않습니다. 환경은 윈도우/안드로이드 입니다. https://github.com/ghgfhfg2/react-native-base

  • react-native
  • typescript
  • nestjs
  • react-query
  • zustand
soo_ya 댓글 2 좋아요 0 조회수 426

3-4 피쳐엔지니어링 인코딩 부분에서 질문

해결됨

[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)

안녕하세요. 3-4 피쳐엔지니어링에 인코딩 부분에서 질문이 있습니다. 파일에선 범주형 칼럼을 추출하기 위해 X_train.columns[X_train.dtypes == object] 를 사용했는데 cols = X_ train.select _dtypes(include= "O").columns 로 해도 동일하게 작업이 가능한가요? 최대한 단순하게 외우고 싶어서 이게 가능하다면 select_dtypes() 사용하는걸로 외우려고요

  • python
  • 머신러닝
  • 빅데이터
  • pandas
  • 빅데이터분석기사
빅분기수강생 댓글 2 좋아요 0 조회수 171

강의 자료 소스코드는 없나요?

미해결

iOS/Android 앱 개발을 위한 실전 React Native - Basic

제목 그대로 강의 자료로 완성된 소스코드는 따로 없는지 문의 드립니다 다른 강의들은 다 주던대

  • react
  • react-native
  • es6
ypd603 댓글 1 좋아요 0 조회수 347

4회 기출 유형(작업형2)

해결됨

[퇴근후딴짓] 빅데이터 분석기사 실기 (작업형1,2,3)

4회 기출 유형(작업형2)까지 수강하였을 때, 제가 이해한 내용은 다음과 같습니다. <모델의 성능을 평가하는 방법> 데이터 분리 (X_tr, X_val, y_tr, y_val) → 모델 학습 & 하이퍼 파라미터 튜닝 → 평가 (f1 score, roc_auc_score 등) 하이퍼 파라미터 튜닝의 값을 조절해가며 평가 점수 확인 데이터 분리 없이, 모델 학습 & 하이퍼 파라미터 튜닝 → 교차검증 (cross_val_score) 이때 질문드립니다. 제가 이해한 대로, 모델의 성능을 평가하는 방법이 위의 2가지가 있는게 맞을까요? 강사님이 영상에서 교차검증을 사용한 이유는 문제에서 평가 방식을 '평가: Macro f1-score'라고 제시해주었기 때문인가요? 혹시 실제 시험 상황에서 평가 방식을 제시해주지 않는다면, 위의 2가지 방법 중 어떤 것을 사용해도 상관이 없는건가요?

  • python
  • 머신러닝
  • 빅데이터
  • pandas
  • 빅데이터분석기사
yb 댓글 1 좋아요 0 조회수 215

인기 태그

인프런 TOP Writers

주간 인기글