Skip to content

Bug/enhancement #850

@jerrycearley

Description

@jerrycearley

Describe the bug

MatchZoo breaks when run in google colab beacause of deprocated dependencies in keras

To Reproduce

Attempt to import match zoo in google colab:

!pip3 install matchzoo

import tensorflow
from tensorflow import keras
import matchzoo as mz
import nltk
import pandas as pd

Describe your attempts

Attempted to run matchzoo in google colab
Fixed dependecy issues

You should also provide code snippets you tried as a workaround, StackOverflow solution that you have walked through, or your best guess of the cause that you can't locate (e.g. cosmic radiation).

Context

Nine FIles Needed edit:
attention layer.py
#from keras.engine import Layer
from keras.layers import Layer # Changed from previous line to fix tensorflow toolchain

data_generator.py
import tensorflow # Added to fix toolchain issues
#import keras
from tensorflow import keras # Changed from previous line

decating_dropout_layer.py
#from keras.engine import Layer
from keras.layers import Layer # Changed from previous line to fix tensorflow toolchain

dynamic_pooling_layer.py
#from keras.engine import Layer
from keras.layers import Layer # Changed from previous line to fix tensorflow toolchain

matching_layer.py
#from keras.engine import Layer
from keras.layers import Layer # Changed from previous line to fix tensorflow toolchain

matching_tensor_layer.py
#from keras.engine import Layer
from keras.layers import Layer # Changed from previous line to fix tensorflow toolchain

multi_perspective_layer.py
#from keras.engine import Layer
from keras.layers import Layer # Changed from previous line to fix tensorflow toolchain

semantic_composite_layer.py
#from keras.engine import Layer
from keras.layers import Layer # Changed from previous line to fix tensorflow toolchain

spatial_gru.py
#from keras.engine import Layer
from keras.layers import Layer # Changed from previous line to fix tensorflow toolchain

Additional Information

I clone the repo and will push this update as a contribution to the code base

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions