Ameer Hamza Nasir — Data & ML Engineer
Machine Learning · Computer Vision · FastAPI · Open Source
// The Builder
// Project 01
Real-time adaptive traffic signal for a 4-way chowk intersection. Pakistan's standard fixed 120s timer wastes green time on empty roads. YOLOv5 detects vehicles per lane. A Greedy scheduler allocates green time based on live congestion — cars queue at the stop line on red and release when it's their turn.
// Project 02
End-to-end pipeline on 284,807 credit card transactions. SMOTE oversampling for class imbalance. XGBoost with stratified k-fold cross-validation. Deployed as FastAPI REST endpoint on AWS EC2.
// Project 03
CNN built in PyTorch on MNIST — 60,000 training images, 99.1% test accuracy. Draw a digit below.
// Open Source
Dockerized proxy eliminating Anthropic billing. Routes Claude Code API through OpenRouter free-tier LLMs. Node.js reverse proxy with real-time format translation and SSE streaming.
// Code
# greedy green-time allocator
import heapq
def allocate_green_time(lanes):
# max-heap by congestion
pq = [(-l['score'], l['id']) for l in lanes]
heapq.heapify(pq)
while pq:
score, lane_id = heapq.heappop(pq)
set_green(lane_id, duration=-score * 2)
# fraud detection pipeline
from xgboost import XGBClassifier
from imblearn.over_sampling import SMOTE
smote = SMOTE(random_state=42)
X_res, y_res = smote.fit_resample(X_train, y_train)
model = XGBClassifier(
n_estimators=300,
max_depth=6,
learning_rate=0.1
)
model.fit(X_res, y_res)
# f1: 0.91 | auc: 0.98
# mnist cnn in pytorch
class Net(nn.Module):
def __init__(self):
super().__init__()
self.conv1 = nn.Conv2d(1, 32, 3)
self.conv2 = nn.Conv2d(32, 64, 3)
self.fc1 = nn.Linear(64*5*5, 128)
self.fc2 = nn.Linear(128, 10)
def forward(self, x):
x = F.relu(F.max_pool2d(
self.conv1(x), 2))
return x
// claudecode proxy - node.js
const http = require('http');
const proxy = http.createServer((req, res) => {
const body = translateFormat(req);
forwardToOpenRouter(body)
.then(data => res.end(data))
.catch(err => res.statusCode=500);
});
proxy.listen(8080, () => {
console.log('Proxy Online');
});
// Contact
Open to data analytics internships, ML engineering roles, and freelance projects. I respond fast.
hamza6700@gmail.com