yushuai / ftanet-melodic Goto Github PK
View Code? Open in Web Editor NEWThis repository is the offical implementation for the paper 《Frequency-Temporal Attention Network for Singing Melody Extraction》.
This repository is the offical implementation for the paper 《Frequency-Temporal Attention Network for Singing Melody Extraction》.
May the brief implementation steps be written in README.md to run the code?
Thanks for your job. I wonder how I can get the f0 frequency in dataset.
`## Load f0 frequency
ref_arr = np.loadtxt(data_folder + 'f0ref/' + fname + '.txt') # (T, 2)`
I mean why the dimension is 2. What else does it record besides frequency?
' def create_model(input_shape=(320, 430, 3)):
visible = Input(shape=input_shape)
x = BatchNormalization()(visible)
## Bottom
# bm = BatchNormalization()(x)
bm = x
bm = Conv2D(16, (4, 1), padding='valid', strides=(4, 1), activation='selu')(bm) # 80
bm = Conv2D(16, (4, 1), padding='valid', strides=(4, 1), activation='selu')(bm) # 20
bm = Conv2D(16, (4, 1), padding='valid', strides=(4, 1), activation='selu')(bm) # 5
bm = Conv2D(1, (5, 1), padding='valid', strides=(5, 1), activation='selu')(bm) # 1
# 保持高分辨率,关注细节
shape=input_shape
x_r, x_t, x_f = FTA_Module(x, (shape[0], shape[1], 32), 3, 3)
x = SF_Module([x_r, x_t, x_f], 32, 4, 4)
x = MaxPooling2D((2, 2))(x)
x_r, x_t, x_f = FTA_Module(x, (shape[0]//2, shape[1]//2, 64), 3, 3)
x = SF_Module([x_r, x_t, x_f], 64, 4, 4)
x = MaxPooling2D((2, 2))(x)
x_r, x_t, x_f = FTA_Module(x, (shape[0]//4, shape[1]//4, 128), 3, 3)
x = SF_Module([x_r, x_t, x_f], 128, 4, 4)
x_r, x_t, x_f = FTA_Module(x, (shape[0]//4, shape[1]//4, 128), 3, 3)
x = SF_Module([x_r, x_t, x_f], 128, 4, 4)
x = UpSampling2D((2, 2))(x)
x_r, x_t, x_f = FTA_Module(x, (shape[0]//2, shape[1]//2, 64), 3, 3)
x = SF_Module([x_r, x_t, x_f], 64, 4, 4)
x = UpSampling2D((2, 2))(x)
x_r, x_t, x_f = FTA_Module(x, (shape[0], shape[1], 32), 3, 3)
x = SF_Module([x_r, x_t, x_f], 32, 4, 4)
x_r, x_t, x_f = FTA_Module(x, (shape[0], shape[1], 1), 3, 3)
x = SF_Module([x_r, x_t, x_f], 1, 4, 4)
x = Concatenate(axis=1)([bm, x])
# Softmax
x = Lambda(K.squeeze, arguments={'axis': -1})(x) # (321, 430)
x = Softmax(axis=-2)(x)
return Model(inputs=visible, outputs=x)`
I run this code in ftanet.py(load your ftanet.h5). Input shape = (320, 430, 3)
Get this error '' ValueError: total size of new array must be unchanged, input_shape = [214, 64], output_shape = [1, 215, 64] ''
I think question is about Upsampling:
x_r, x_t, x_f = FTA_Module(x, (shape[0]//4, shape[1]//4, 128), 3, 3)
x = SF_Module([x_r, x_t, x_f], 128, 4, 4) --------------------------> shape : (None, 80, 107, 128)
x = UpSampling2D((2, 2))(x)-----------------------------------------> shape: (None, 160, 214, 128)
x_r, x_t, x_f = FTA_Module(x, (shape[0]//2, shape[1]//2, 64), 3, 3)----> input shape : (None, 160, 215, 128)
How do you train your model? Initial Input shape is correct?
Hello seniors, do you have pytorch version of visualization script
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.