Opened 2 months ago
Closed 2 months ago
#18488 closed defect (fixed)
AlphaFold prediction fails with a TensorFlow error
Reported by: | Tom Goddard | Owned by: | Tom Goddard |
---|---|---|---|
Priority: | moderate | Milestone: | |
Component: | Structure Prediction | Version: | |
Keywords: | Cc: | ||
Blocked By: | Blocking: | ||
Notify when closed: | Platform: | all | |
Project: | ChimeraX |
Description
Colabfold Colab tensorflow error
Please cite ColabFold: Making protein folding accessible to all. Nature Methods (2022) if you use these predictions.
/tmp/ipython-input-755078088.py:117: DeprecationWarning: datetime.datetime.utcnow() is deprecated and scheduled for removal in a future version. Use timezone-aware objects to represent datetimes in UTC: datetime.datetime.now(datetime.UTC).
% datetime.datetime.utcnow().strftime('%Y-%m-%d'))
INFO:main__:Starting prediction on 2025-08-20 UTC time
INFO:main__:Installing ColabFold on Google Colab virtual machine.
Installing ColabFold
Using Tesla T4 graphics processor
Downloading alphafold2_ptm weights to .: 100%|██████████| 3.47G/3.47G [01:28<00:00, 42.3MB/s]
RuntimeError Traceback (most recent call last)
/usr/local/lib/python3.12/dist-packages/colabfold/batch.py in run(queries, result_dir, num_models, is_complex, num_recycles, recycle_early_stop_tolerance, model_order, num_ensemble, model_type, msa_mode, use_templates, custom_template_path, num_relax, relax_max_iterations, relax_tolerance, relax_stiffness, relax_max_outer_iterations, keep_existing_results, rank_by, pair_mode, pairing_strategy, data_dir, host_url, user_agent, random_seed, num_seeds, recompile_padding, zip_results, prediction_callback, save_single_representations, save_pair_representations, jobname_prefix, save_all, save_recycles, use_dropout, use_gpu_relax, stop_at_score, dpi, max_seq, max_extra_seq, pdb_hit_file, local_pdb_path, use_cluster_profile, feature_dict_callback, calc_extra_ptm, use_probs_extra, kwargs)
1293 import jax.tools.colab_tpu
-> 1294 jax.tools.colab_tpu.setup_tpu()
1295 logger.info('Running on TPU')
5 frames
RuntimeError: jax.tools.colab_tpu.setup_tpu() was required for older JAX versions running on older generations of TPUs, and should no longer be used.
During handling of the above exception, another exception occurred:
NotFoundError Traceback (most recent call last)
/usr/local/lib/python3.12/dist-packages/tensorflow/python/framework/load_library.py in load_library(library_location)
149
150 for lib in kernel_libraries:
--> 151 py_tf.TF_LoadLibrary(lib)
152
153 else:
NotFoundError: /usr/local/lib/python3.12/dist-packages/tensorflow/core/kernels/libtfkernel_sobol_op.so: undefined symbol: _ZN10tensorflow15TensorShapeBaseINS_11TensorShapeEEC2EN4absl12lts_202308024SpanIKlEE
Fixed.
Apparently Google Colab updated TensorFlow which caused this shared library missing symbol error. The ColabFold repository fixed it 5 days ago by deleting the offending library
I added the same fix to the ChimeraX Colab script which fixed the problem.