<jupyter_start><jupyter_text>import image<jupyter_code>cd E:\Siyan Zhou\mask\with_optical_image_whole
f = Image.open("Mask_Segmentation_W_11-1 (8.16).vsseg_export_s0000"+".png")
im = np.asarray(f)
im.shape
560%100<jupyter_output><empty_output><jupyter_text>2D skeletonize and superimpose<jupyter_code>skeleton = np.zeros((6736,12482),dtype = "uint8")
for i in tqdm(range(1416)):
    f = Image.open("Mask_Segmentation_W_11-1 (8.16).vsseg_export_s"+str("%04d"%i)+".png")
    im = (np.asarray(f) > 0)
    s = morphology.skeletonize(im)
    skeleton = skeleton + s
    if i%100 == 0:
        scipy.misc.imsave('topview'+str(i)+'.png', skeleton)
plt.imshow(100*skeleton)<jupyter_output><empty_output><jupyter_text>import NMJ coordinates<jupyter_code>nmj = np.zeros((6736,12482),dtype = "uint8")
cd E:\Siyan Zhou\mask\nmj
a = np.loadtxt('nmj.txt')
a.shape<jupyter_output><empty_output><jupyter_text>overlap<jupyter_code>for i in tqdm(range(260)):
    x = math.floor(a[i][1]/32)
    y = math.floor(a[i][0]/32)
    nmj[x-30:x+30,y-30:y+30]=1
fig,ax = plt.subplots(1,1,figsize = (20,20))
ax.imshow(100*nmj)
cd E:\Siyan Zhou\mask\with_optical_image_whole
f = Image.open("top_view_gamma.png")
im = np.asarray(f)
plt.imshow(im)
merge = np.zeros((nmj.shape[0],nmj.shape[1],3))
merge[:,:,2]=nmj*255
merge[:,:,1]=im
plt.imshow(merge)
cv2.imwrite('merge.png',merge)
scipy.misc.imsave('nmj.png', 100*nmj)<jupyter_output>C:\Users\Harvard\Anaconda3\lib\site-packages\ipykernel_launcher.py:1: DeprecationWarning: `imsave` is deprecated!
`imsave` is deprecated in SciPy 1.0.0, and will be removed in 1.2.0.
Use ``imageio.imwrite`` instead.
  """Entry point for launching an IPython kernel.
{'fraction_non_alphanumeric': 0.17985611510791366, 'fraction_numerical': 0.06235011990407674, 'mean_word_length': 6.163090128755365, 'pattern_counts': {'":': 0, '<': 16, '<?xml version=': 0, '>': 17, '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': '4', 'dir': 'jupyter-structured-clean-dedup', 'id': '401727', 'license': 'MIT', 'n_tokens_mistral': 792, 'n_tokens_neox': 723, 'n_words': 101, 'path': 'skeleton_of_masks/skeleton_masks_to_compare_with_confocal_image.ipynb', 'repo_name': 'SiyanZHOU1997/Neuromuscular_connectome_reconstruction', 'size': '1668'}