Skip to content

Azmvv/aboutdclocate

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 

Repository files navigation

DCLocate — Data Center Site Selection & Analytics System

A multi-criteria decision support system that identifies the optimal locations for building data centers.

🌐 Live demo: https://dclocate.com

DCLocate landing page

🏗️ Architecture

┌─────────────┐     ┌──────────────┐     ┌───────────────────┐
│  React UI   │────▶│  FastAPI      │────▶│ PostgreSQL+PostGIS │
│  (Vite+TS)  │     │  Backend      │     │                    │
│  Recharts   │     │  Scoring Eng. │     │  Spatial Queries   │
│  Mapbox GL  │     │  NASA POWER   │     └───────────────────┘
└─────────────┘     └──────┬───────┘
                           │
                    ┌──────▼───────┐
                    │    Redis     │
                    │ (Cache/Queue)│
                    └──────────────┘

✨ Key Features

  • Discovery Engine — automatically scans a country and surfaces top data center candidate locations scored on multiple factors.
  • Weighted Scoring — score and compare locations using customizable weights across climate, infrastructure, risk, economics and connectivity.
  • TCO Calculator — estimate total cost of ownership and compare countries side by side over the project lifetime.
  • Risk Assessment — evaluate seismic, flood, hurricane and wildfire exposure with real-world hazard data.
  • Privacy & Compliance — built-in GDPR / KVKK controls, audit logging and data sovereignty management.
  • Reports & Export — export analysis to CSV and multi-sheet Excel, or generate detailed PDF reports.
  • Multi-language UI — available in 9 languages (English, Turkish, German, French, Japanese, Korean, Arabic, Portuguese, Chinese) with RTL support.

📊 Analysis Criteria

Category Parameters Default Weight
Climate Temperature, Humidity, Precipitation, Wind, Free-cooling hours 25%
Infrastructure Grid capacity, Water supply, Airport, Highway 25%
Risk Earthquake, Flood, Hurricane, Wildfire, Political stability 25%
Economics Electricity cost, Land, Tax, Incentives 15%
Connectivity Fiber, IXP, Latency 10%

🚀 Quick Start

With Docker (recommended)

# Start all services
docker compose up --build

# API:      http://localhost:8000
# Swagger:  http://localhost:8000/docs
# Frontend: http://localhost:3000

Manual Development

Backend:

cd apps/api
python -m venv .venv && source .venv/bin/activate
pip install -r requirements.txt
cp .env.example .env  # edit your settings
uvicorn app.main:app --reload

Frontend:

cd apps/web
npm install
npm run dev

Requirements:

  • Python 3.11+
  • Node.js 22+
  • PostgreSQL 16 + PostGIS 3.4
  • Redis 7+

📡 API Endpoints

Method Endpoint Description
GET /health Health check
POST /api/v1/sites/ Add a new location
GET /api/v1/sites/ List locations
GET /api/v1/sites/{id} Detailed location info
POST /api/v1/sites/{id}/enrich-climate Fetch climate data from NASA POWER
POST /api/v1/scoring/compute Single-location scoring
POST /api/v1/scoring/bulk Bulk scoring
GET /api/v1/analysis/{id}/report-card Pros/cons report card
POST /api/v1/analysis/compare Compare locations
GET /api/v1/analysis/heatmap GeoJSON heatmap data

📁 Project Structure

DataCenterArea/
├── apps/
│   ├── api/                    # FastAPI Backend
│   │   ├── app/
│   │   │   ├── api/routes/     # HTTP endpoints
│   │   │   ├── core/           # Config, DB engine
│   │   │   ├── models/         # SQLAlchemy ORM
│   │   │   ├── schemas/        # Pydantic schemas
│   │   │   └── services/       # Business logic
│   │   ├── Dockerfile
│   │   └── requirements.txt
│   └── web/                    # React Frontend
│       ├── src/
│       │   ├── app/            # App shell & routing
│       │   ├── components/     # UI components
│       │   ├── locales/        # i18n translations (9 languages)
│       │   ├── services/       # API client
│       │   └── types/          # TypeScript types
│       ├── Dockerfile
│       └── package.json
├── docker-compose.yml
└── docker-compose.prod.yml     # Production deployment

🔧 Scoring Engine

Each category is scored from 0–100. Users can assign a weight to every category.

Total Score = Σ (category_score × weight)

PUE Estimate = automatically computed from temperature and humidity data (1.0 ideal → 2.5 poor)

📝 License

MIT

About

No description, website, or topics provided.

Resources

Stars

1 star

Watchers

0 watching

Forks

Releases

No releases published

Packages

 
 
 

Contributors