sokrypton / ColabDesign

Making Protein Design accessible to all via Google Colab!
529 stars 118 forks source link

af_model.predict failing #170

Closed baptiste-roelens closed 5 months ago

baptiste-roelens commented 5 months ago

Not sure how recent this is, but the AlphaFold prediction, as implemented for instance in the ProteinMPNN in Jax! notebook does not run on Colab any more. The following code: af_model = mk_af_model(data_dir="/content/params",best_metric="dgram_cce") af_model.prep_inputs(pdb_filename=pdb_path) af_model.predict(seq=seq, num_recycles=1, num_models=1, temp=0.1, verbose=True)

results in the following error: /usr/local/lib/python3.10/dist-packages/colabdesign/af/alphafold/model/utils.py in mask_mean(mask, value, axis, drop_mask_channel, eps) 53 elif axis is None: 54 axis = list(range(len(mask_shape))) ---> 55 assert isinstance(axis, collections.Iterable), ( 56 'axis needs to be either an iterable, integer or "None"') 57

AttributeError: module 'collections' has no attribute 'Iterable'

sokrypton commented 5 months ago

Which notebook you are using?

baptiste-roelens commented 5 months ago

Looks like I was using an outdated version of the notebook installing ColabDesign v1.1.0, instead of 1.1.1, sorry for the confusion.