Rishab7310 commited on
Commit
f179d44
·
verified ·
1 Parent(s): 74ee2f2

Create notebooks/feature_extraction.ipynb

Browse files
Files changed (1) hide show
  1. notebooks/feature_extraction.ipynb +22 -0
notebooks/feature_extraction.ipynb ADDED
@@ -0,0 +1,22 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ import torch
2
+ import torch.nn as nn
3
+ import torch.optim as optim
4
+ from torch.utils.data import DataLoader, Dataset
5
+ import torchvision.transforms as transforms
6
+ from PIL import Image
7
+ import numpy as np
8
+ import matplotlib.pyplot as plt
9
+ from pathlib import Path
10
+ import os
11
+ import sys
12
+
13
+ # Add the project root to Python path for imports
14
+ project_root = Path.cwd().parent
15
+ sys.path.insert(0, str(project_root))
16
+ sys.path.insert(0, str(project_root / 'models'))
17
+
18
+ # Import our custom CNN model
19
+ # Note: These imports work at runtime even if IDE shows warnings
20
+ from models.cnn_feature_extractor import KolamFeatureExtractor # type: ignore
21
+
22
+ print("Feature extraction setup complete!")