<jupyter_start><jupyter_text>Imports<jupyter_code>import os
import numpy as np
import pandas as pd<jupyter_output><empty_output><jupyter_text>Explore the data  Read data<jupyter_code>data_folder = os.path.join('..', 'data')
df = pd.read_csv(os.path.join(data_folder, 'sensor.csv'))
df.shape
df.head()<jupyter_output><empty_output><jupyter_text>Set data index<jupyter_code>df.index = pd.to_datetime(df.timestamp)
df.drop(['Unnamed: 0', 'timestamp'], axis=1, inplace=True)
print(f'Sample freq std: {(df.index[1:] - df.index[:-1]).std()}')
print(f'Sample freq mean: {(df.index[1:] - df.index[:-1]).mean()}')<jupyter_output>Sample freq std: 0 days 00:00:00
Sample freq mean: 0 days 00:01:00<jupyter_text>We can see that the sensors are measured in constants frequancy of 1sample/min<jupyter_code>df.isnull().mean()<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.16428571428571428, 'fraction_numerical': 0.025, 'mean_word_length': 7.852631578947369, 'pattern_counts': {'":': 0, '<': 16, '<?xml version=': 0, '>': 16, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '477480', 'license': 'MIT', 'n_tokens_mistral': 345, 'n_tokens_neox': 328, 'n_words': 62, 'path': 'notebooks/EDA.ipynb', 'repo_name': 'Omerdan03/pump_sensor_data', 'size': '840'}