stared / livelossplot

Live training loss plot in Jupyter Notebook for Keras, PyTorch and others
https://p.migdal.pl/livelossplot
MIT License
1.29k stars 143 forks source link

AttributeError in jupyter #50

Closed Uwemat closed 5 years ago

Uwemat commented 5 years ago

Hi! I'm new to TF and keras and wanted to try out 'livelossplot'. I get the following Error:

AttributeError: module 'neptune' has no attribute 'Context'

This is my code:

` model.compile(loss='binary_crossentropy', optimizer='adam', metrics=['accuracy', 'mean_squared_error'])

plot_losses = PlotLossesCallback()

model.fit(X_train, y_train, epochs=2, batch_size=1, validation_data=(X_test, y_test), callbacks=[plot_losses], verbose=0)

AttributeError Traceback (most recent call last)

in 4 5 ----> 6 plot_losses = PlotLossesCallback() 7 8 model.fit(X_train, y_train, D:\Programme\Anaconda3\envs\tensorflow_env\lib\site-packages\livelossplot\keras.py in __init__(self, **kwargs) 7 def __init__(self, **kwargs): 8 keras.callbacks.Callback.__init__(self) ----> 9 _PlotLossesCallback.__init__(self, **kwargs) D:\Programme\Anaconda3\envs\tensorflow_env\lib\site-packages\livelossplot\generic_keras.py in __init__(self, **kwargs) 26 class _PlotLossesCallback(): 27 def __init__(self, **kwargs): ---> 28 self.liveplot = PlotLosses(**kwargs) 29 30 def on_train_begin(self, logs={}): D:\Programme\Anaconda3\envs\tensorflow_env\lib\site-packages\livelossplot\generic_plot.py in __init__(self, figsize, cell_size, dynamic_x_axis, max_cols, max_epoch, metric2title, series_fmt, validation_fmt, plot_extrema, fig_path, target) 37 self.plot_extrema = plot_extrema 38 self.target = target ---> 39 from .neptune_integration import neptune_send_plot 40 self.fig_path = fig_path 41 D:\Programme\Anaconda3\envs\tensorflow_env\lib\site-packages\livelossplot\neptune_integration.py in 1 import neptune 2 ----> 3 ctx = neptune.Context() 4 5 AttributeError: module 'neptune' has no attribute 'Context'` Any idea?
stared commented 5 years ago

@Uwemat Thanks for reporting, duplicate of #51