전체 글
-
4/22카테고리 없음 2022. 4. 26. 19:41
# 4/22 IPyton : Interactive python 복수의 프로그래밍 언어에서 상호작용적인 컴퓨팅을 하기 위한 명령 셸이며 파이썬 프로그래밍 언어용으로 처음 개발되었다. 자가 검사, 대화형 매체, 셸 문법, 탭 완성, 히스토리를 제공한다. IPython은 다음 기능을 제공한다: # tf.constant() : 변하지 않는 상수 생성 # tf.Variable() : 값이 바뀔 수도 있는 변수 생성 tf.Session() -> tf.Session().run(tf.global_variables_initializer()) -> tf.Session().run(tf.constant/tf.Variable) -> tf.Session().run(y, feed_dict={x:tf.placeholder}) -> ..
-
4/19카테고리 없음 2022. 4. 24. 15:24
# 4/19 with py7zr.SevenZipFile('./input/train.7z', 'r') as acheive: acheive.extractall(path='./input/train/') from scipy.io import wavfile from scipy import signal from scipy.fftpack import fft import librosa # load-fm/ptdb/ds-fm/fd/ds wavefile.read('')->signal.spectrogram()-> librosa.load('') -> librosa.feature.melspectrogram -> ipd.Audio(samples[4000:13000], rate=sample_rate) # 침묵제거 -> fft -> ..
-
4/14카테고리 없음 2022. 4. 22. 17:01
# 4/14 train.shape train.drop_duplicates() train.shape desired_apriori=0.10 idx_0 = train[train.target == 0].index idx_1 = train[train.target == 1].index nb_0 = len(train.loc[idx_0]) nb_1 = len(train.loc[idx_1]) undersampling_rate = ((1-desired_apriori)*nb_1)/(nb_0*desired_apriori) undersampled_nb_0 = int(undersampling_rate*nb_0) undersampled_idx = shuffle(idx_0, random_state=37, n_samples=under..