<jupyter_start><jupyter_text>Data Loading<jupyter_code>from google.colab import drive
drive.mount('/content/drive')
!unzip drive/"MyDrive/CS 7643 Project/ModelNet10.zip"
!unzip drive/"MyDrive/CS 7643 Project/shrec_16.zip"
import os
path = "ModelNet10"

folders = [dir for dir in sorted(os.listdir(path))]
classes = {folder: i for i, folder in enumerate(folders)};
classes
def read_off(file):
    if 'OFF' != file.readline().strip():
        raise('Not a valid OFF header')
    n_verts, n_faces, __ = tuple([int(s) for s in file.readline().strip().split(' ')])
    verts = [[float(s) for s in file.readline().strip().split(' ')] for i_vert in range(n_verts)]
    faces = [[int(s) for s in file.readline().strip().split(' ')][1:] for i_face in range(n_faces)]
    return n_verts, n_faces, verts, faces
with open(path + "/sofa/train/sofa_0002.off", 'r') as f:
    n_verts, n_faces, verts, faces = read_off(f)    
n_verts, n_faces<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.16213389121338911, 'fraction_numerical': 0.0198744769874477, 'mean_word_length': 4.765060240963855, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, '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': '1', 'dir': 'jupyter-structured-clean-dedup', 'id': '331712', 'license': 'MIT', 'n_tokens_mistral': 368, 'n_tokens_neox': 349, 'n_words': 89, 'path': '.ipynb_checkpoints/DataLoadingOFF-checkpoint.ipynb', 'repo_name': 'EkanshGupta/MeshCNN', 'size': '956'}