<jupyter_start><jupyter_text>Import Python libraries<jupyter_code>from rdkit import Chem
from rdkit.Chem import PandasTools,Draw
import seaborn as sns
import pandas as pd
import matplotlib.pyplot as plt
import matplotlib<jupyter_output><empty_output><jupyter_text>Necessary setup for SVG images<jupyter_code>from rdkit.Chem.Draw import IPythonConsole
from rdkit.Chem import rdDepictor
IPythonConsole.ipython_useSVG = True
rdDepictor.SetPreferCoordGen(True)<jupyter_output><empty_output><jupyter_text>Load the SDF that was output by transformer_search.py<jupyter_code>df = PandasTools.LoadSDF("out.sdf")<jupyter_output><empty_output><jupyter_text>Draw the molecule pairs.  Change molsPerRow and subImgSize to make images bigger<jupyter_code>Draw.MolsToGridImage([x for x in df.ROMol],molsPerRow=4,legends=["%.0f" % float(x) for x in df.Value],subImgSize=(200, 200))<jupyter_output><empty_output><jupyter_text>Set up data for plotting<jupyter_code>ip = [float(x[1]) for x in enumerate(df.Value) if x[0] % 2 == 0]
tp = [float(x[1]) for x in enumerate(df.Value) if x[0] % 2 == 1]
x = ["IP"]* len(first) + ["TP"] * len(second)
y = ip + tp<jupyter_output><empty_output><jupyter_text>Make a plot comparing the PIM1 IC50 for the two scaffolds being considered```IP = imidazo[1,2‐b]pyridazineTP = 3H‐[1,2,3]triazolo[4,5‐b]pyridine```<jupyter_code>sns.set(rc={'figure.figsize': (15, 12)})
sns.set(font_scale=1.5)
sns.set_style('whitegrid')
ax = sns.scatterplot(x,y)
ax.set(xlabel="Scaffold",ylabel="PIM1 IC50 (nM)")
ax.set_yscale('log')
ax.set_yticks([0,10,25,50,100,200])
ax.get_yaxis().set_major_formatter(matplotlib.ticker.ScalarFormatter())
for f,s in zip(first,second):
    plt.plot([0,1],[f,s],color="black")<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.14302191464821223, 'fraction_numerical': 0.029411764705882353, 'mean_word_length': 8.532967032967033, 'pattern_counts': {'":': 0, '<': 25, '<?xml version=': 0, '>': 25, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '6', 'dir': 'jupyter-structured-clean-dedup', 'id': '411155', 'license': 'MIT', 'n_tokens_mistral': 734, 'n_tokens_neox': 685, 'n_words': 129, 'path': 'view_pairs.ipynb', 'repo_name': 'PatWalters/transformer', 'size': '1734'}