Merging Datasets from Different Timescales | HackerNoon

  • 📰 hackernoon
  • ⏱ Reading Time:
  • 26 sec. here
  • 2 min. at publisher
  • 📊 Quality Score:
  • News: 14%
  • Publisher: 51%

Education Education Headlines News

Education Education Latest News,Education Education Headlines

One of the trickiest situations in machine learning is when you have to deal with datasets coming from different time scales. - data datasets

Using deep neural networks it is possible to do this vert smoothly. You can create two subnetworks: one network reads the daily data, and the other network reads the monthly data. The outputs of the two subnetworks are then joined together before they are passed into another layer. The code below shows how you could do this for the two datasets we outlined above.

import pandas as pd from tensorflow import keras from tensorflow.keras import layers from tensorflow.keras.layers import X_day=pd.read_csv X_month=pd.read_csv day_input=keras.Input monthly_input=keras.Input x1=LSTM x2=Dense merging=Concatenate x=Dense x=BatchNormalization x=Dropout y=DenseThe benefit of using deep learning, in this case, is that you are not losing any information which would have been lost otherwise by aggregating features together. This is done through the use of a layer, like

 

Thank you for your comment. Your comment will be published after being reviewed.
Please try again later.
We have summarized this news so that you can read it quickly. If you are interested in the news, you can read the full text here. Read more:

 /  🏆 532. in EDUCATÄ°ON

Education Education Latest News, Education Education Headlines