<jupyter_start><jupyter_text>Mapping Calibration<jupyter_code>df = pd.read_csv('./datasets/pot_cal_dataset_clean_1.csv') # dataset generated during calibration run
df # prints pot ADC values<jupyter_output><empty_output><jupyter_text>- shoulder    - min        - angle:-90        - ADC: 203            - max        - angle: 0        - ADC: 599- elbow    - min        - angle: 0        - ADC: 865    - max        - angle: 90            - extrapolated angle: 145        - ADC: 490            - extrapolated ADC: 261<jupyter_code>m = (865 - 490)/(0 - 90)

y_145 = m*145 + 865
y_145
# df['Shoulder'] = df.apply(lambda x: map_func(df['Shoulder'], 203, 599, -90, 0))
# df['Elbow'] = df.apply(lambda x: map_func(df['Elbow'], 865, 261, 0, 145))

df = adc2angle(df)
df # prints pot converted angle values<jupyter_output><empty_output><jupyter_text>Converting ADC Values of Traced Image to Angles<jupyter_code>df = pd.read_csv('./datasets/hyster_dataset_clean_1.csv') # second_trial_3.csv is the results of the traced image
df = df.dropna()
df = adc2angle(df)
df.to_csv('angles_1.csv', index=False)
df = pd.read_csv('./datasets/hyster_dataset_clean_5.csv') # second_trial_3.csv is the results of the traced image
df = df.dropna()
df = adc2angle(df)
df.to_csv('angles_5.csv', index=False)<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.13389441469013008, 'fraction_numerical': 0.056618209640397855, 'mean_word_length': 3.4948453608247423, 'pattern_counts': {'":': 0, '<': 13, '<?xml version=': 0, '>': 13, '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': '3', 'dir': 'jupyter-structured-clean-dedup', 'id': '166667', 'license': 'MIT', 'n_tokens_mistral': 539, 'n_tokens_neox': 466, 'n_words': 109, 'path': 'deliverables/del_e/pot_calibration/pot_calibration.ipynb', 'repo_name': 'cplan082-tech/project_csi4103', 'size': '1307'}