GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.

Code Duplication    Length = 39-39 lines in 3 locations

voltcycle/core.py 1 location

@@ 531-569 (lines=39) @@
528
    return ratio
529
530
531
def data_analysis(df):
532
    results_dict = {}
533
534
    # df = main.data_frame(dict_1,1)
535
    x = df['Potential']
536
    y = df['Current']
537
    # Peaks are here [list]
538
    peak_index = core.peak_detection_fxn(y)
539
    # Split x,y to get baselines
540
    x1,x2 = core.split(x)
541
    y1,y2 = core.split(y)
542
    y_base1 = core.linear_background(x1,y1)
543
    y_base2 = core.linear_background(x2,y2)
544
    # Calculations based on baseline and peak
545
    values = core.peak_values(x,y)
546
    Et = values[0]
547
    Eb = values[2]
548
    dE = core.del_potential(x,y)
549
    half_E = min(Et,Eb) + core.half_wave_potential(x,y)
550
    ia = core.peak_heights(x,y)[0]
551
    ic = core.peak_heights(x,y)[1]
552
    ratio_i = core.peak_ratio(x,y)
553
    results_dict['Peak Current Ratio'] = ratio_i
554
    results_dict['Ipc (A)'] = ic
555
    results_dict['Ipa (A)'] = ia
556
    results_dict['Epc (V)'] = Eb
557
    results_dict['Epa (V)'] = Et
558
    results_dict['∆E (V)'] = dE
559
    results_dict['Redox Potential (V)'] = half_E
560
    if dE>0.3:
561
        results_dict['Reversible'] = 'No'
562
    else:
563
        results_dict['Reversible'] = 'Yes'
564
565
    if half_E>0 and  'Yes' in results_dict.values():
566
        results_dict['Type'] = 'Catholyte'
567
    elif 'Yes' in results_dict.values():
568
        results_dict['Type'] = 'Anolyte'
569
    return results_dict, x1, x2, y1, y2, y_base1, y_base2, peak_index
570
    #return results_dict
571

app/app.py 1 location

@@ 148-186 (lines=39) @@
145
        return df
146
147
148
def data_analysis(df):
149
    results_dict = {}
150
151
    # df = main.data_frame(dict_1,1)
152
    x = df['Potential']
153
    y = df['Current']
154
    # Peaks are here [list]
155
    peak_index = core.peak_detection_fxn(y)
156
    # Split x,y to get baselines
157
    x1,x2 = core.split(x)
158
    y1,y2 = core.split(y)
159
    y_base1 = core.linear_background(x1,y1)
160
    y_base2 = core.linear_background(x2,y2)
161
    # Calculations based on baseline and peak
162
    values = core.peak_values(x,y)
163
    Et = values[0]
164
    Eb = values[2]
165
    dE = core.del_potential(x,y)
166
    half_E = min(Et,Eb) + core.half_wave_potential(x,y)
167
    ia = core.peak_heights(x,y)[0]
168
    ic = core.peak_heights(x,y)[1]
169
    ratio_i = core.peak_ratio(x,y)
170
    results_dict['Peak Current Ratio'] = ratio_i
171
    results_dict['Ipc (A)'] = ic
172
    results_dict['Ipa (A)'] = ia
173
    results_dict['Epc (V)'] = Eb
174
    results_dict['Epa (V)'] = Et
175
    results_dict['∆E (V)'] = dE
176
    results_dict['Redox Potential (V)'] = half_E
177
    if dE>0.3:
178
        results_dict['Reversible'] = 'No'
179
    else:
180
        results_dict['Reversible'] = 'Yes'
181
    
182
    if half_E>0 and  'Yes' in results_dict.values():
183
        results_dict['Type'] = 'Catholyte'
184
    elif 'Yes' in results_dict.values():
185
        results_dict['Type'] = 'Anolyte'
186
    return results_dict, x1, x2, y1, y2, y_base1, y_base2, peak_index
187
    #return results_dict
188
189

practice/final_dash.py 1 location

@@ 147-185 (lines=39) @@
144
    return df
145
146
147
def data_analysis(df):
148
    results_dict = {}
149
150
    # df = main.data_frame(dict_1,1)
151
    x = df['Potential']
152
    y = df['Current']
153
    # Peaks are here [list]
154
    peak_index = core.peak_detection_fxn(y)
155
    # Split x,y to get baselines
156
    x1,x2 = core.split(x)
157
    y1,y2 = core.split(y)
158
    y_base1 = core.linear_background(x1,y1)
159
    y_base2 = core.linear_background(x2,y2)
160
    # Calculations based on baseline and peak
161
    values = core.peak_values(x,y)
162
    Et = values[0]
163
    Eb = values[2]
164
    dE = core.del_potential(x,y)
165
    half_E = min(Et,Eb) + core.half_wave_potential(x,y)
166
    ia = core.peak_heights(x,y)[0]
167
    ic = core.peak_heights(x,y)[1]
168
    ratio_i = core.peak_ratio(x,y)
169
    results_dict['Peak Current Ratio'] = ratio_i
170
    results_dict['Ipc'] = ic
171
    results_dict['Ipa'] = ia
172
    results_dict['Epc'] = Eb
173
    results_dict['Epa'] = Et
174
    results_dict['∆E'] = dE
175
    results_dict['Redox Potential'] = half_E
176
    if dE>0.3:
177
        results_dict['Reversible'] = 'No'
178
    else:
179
        results_dict['Reversible'] = 'Yes'
180
    
181
    if half_E>0 and  'Yes' in results_dict.values():
182
        results_dict['Type'] = 'Catholyte'
183
    elif 'Yes' in results_dict.values():
184
        results_dict['Type'] = 'Anolyte'
185
    return results_dict
186
187
188
@app.callback(Output('output_uploaded_file', 'children'),