diff --git a/App.js b/App.js deleted file mode 100644 index 3f8ca8f..0000000 --- a/App.js +++ /dev/null @@ -1,71 +0,0 @@ -document.addEventListener('DOMContentLoaded', () => { - const map = L.map('map').setView([18.5204, 73.8567], 13); - - L.tileLayer('https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png', { - attribution: '© OpenStreetMap contributors' - }).addTo(map); - - const markers = {}; - let peakCrowd = 0; - let totalCrowd = 0; - let numberOfShops = 0; - - function createIcon(color) { - return L.divIcon({ - className: 'custom-icon', - html: `
`, - iconSize: [20, 20] - }); - } - - function updateMap() { - fetch('/data') - .then(response => response.json()) - .then(data => { - let maxCrowd = 0; - let minCrowd = Infinity; - let minCrowdLocation = ''; - let preferredShop = ''; - - data.forEach(item => { - const key = `${item.lat},${item.lng}`; - const color = item.count > 10 ? 'red' : 'yellow'; - - if (!markers[key]) { - const marker = L.marker([item.lat, item.lng], { icon: createIcon(color) }).addTo(map) - .bindPopup(`Shop Count: ${item.count}`); - markers[key] = marker; - } else { - markers[key].setPopupContent(`Shop Count: ${item.count}`); - markers[key].setIcon(createIcon(color)); - } - - // Calculate statistics - if (item.count > maxCrowd) { - maxCrowd = item.count; - } - if (item.count < minCrowd) { - minCrowd = item.count; - minCrowdLocation = `${item.lat},${item.lng}`; - } - - totalCrowd += item.count; - numberOfShops++; - }); - - // Update statistics - const averageCrowd = numberOfShops > 0 ? (totalCrowd / numberOfShops).toFixed(2) : 0; - peakCrowd = maxCrowd; - - document.getElementById('peak-crowd').textContent = peakCrowd; - document.getElementById('average-crowd').textContent = averageCrowd; - document.getElementById('preferred-shop').textContent = minCrowdLocation ? `Shop Location: ${minCrowdLocation} with crowd: ${minCrowd}` : 'No data available'; - }) - .catch(error => { - console.error('Error fetching data:', error); - }); - } - - updateMap(); - setInterval(updateMap, 5000); -}); diff --git a/CNAME b/CNAME deleted file mode 100644 index 7143fa5..0000000 --- a/CNAME +++ /dev/null @@ -1 +0,0 @@ -hack2skillexample.com \ No newline at end of file diff --git a/MobileNetSSD_deploy.caffemodel b/MobileNetSSD_deploy.caffemodel deleted file mode 100644 index 7104f06..0000000 Binary files a/MobileNetSSD_deploy.caffemodel and /dev/null differ diff --git a/MobileNetSSD_deploy.prototxt b/MobileNetSSD_deploy.prototxt deleted file mode 100644 index fdc8126..0000000 --- a/MobileNetSSD_deploy.prototxt +++ /dev/null @@ -1,1912 +0,0 @@ -name: "MobileNet-SSD" -input: "data" -input_shape { - dim: 1 - dim: 3 - dim: 300 - dim: 300 -} -layer { - name: "conv0" - type: "Convolution" - bottom: "data" - top: "conv0" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 32 - pad: 1 - kernel_size: 3 - stride: 2 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv0/relu" - type: "ReLU" - bottom: "conv0" - top: "conv0" -} -layer { - name: "conv1/dw" - type: "Convolution" - bottom: "conv0" - top: "conv1/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 32 - pad: 1 - kernel_size: 3 - group: 32 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv1/dw/relu" - type: "ReLU" - bottom: "conv1/dw" - top: "conv1/dw" -} -layer { - name: "conv1" - type: "Convolution" - bottom: "conv1/dw" - top: "conv1" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 64 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv1/relu" - type: "ReLU" - bottom: "conv1" - top: "conv1" -} -layer { - name: "conv2/dw" - type: "Convolution" - bottom: "conv1" - top: "conv2/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 64 - pad: 1 - kernel_size: 3 - stride: 2 - group: 64 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv2/dw/relu" - type: "ReLU" - bottom: "conv2/dw" - top: "conv2/dw" -} -layer { - name: "conv2" - type: "Convolution" - bottom: "conv2/dw" - top: "conv2" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 128 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv2/relu" - type: "ReLU" - bottom: "conv2" - top: "conv2" -} -layer { - name: "conv3/dw" - type: "Convolution" - bottom: "conv2" - top: "conv3/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 128 - pad: 1 - kernel_size: 3 - group: 128 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv3/dw/relu" - type: "ReLU" - bottom: "conv3/dw" - top: "conv3/dw" -} -layer { - name: "conv3" - type: "Convolution" - bottom: "conv3/dw" - top: "conv3" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 128 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv3/relu" - type: "ReLU" - bottom: "conv3" - top: "conv3" -} -layer { - name: "conv4/dw" - type: "Convolution" - bottom: "conv3" - top: "conv4/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 128 - pad: 1 - kernel_size: 3 - stride: 2 - group: 128 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv4/dw/relu" - type: "ReLU" - bottom: "conv4/dw" - top: "conv4/dw" -} -layer { - name: "conv4" - type: "Convolution" - bottom: "conv4/dw" - top: "conv4" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 256 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv4/relu" - type: "ReLU" - bottom: "conv4" - top: "conv4" -} -layer { - name: "conv5/dw" - type: "Convolution" - bottom: "conv4" - top: "conv5/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 256 - pad: 1 - kernel_size: 3 - group: 256 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv5/dw/relu" - type: "ReLU" - bottom: "conv5/dw" - top: "conv5/dw" -} -layer { - name: "conv5" - type: "Convolution" - bottom: "conv5/dw" - top: "conv5" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 256 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv5/relu" - type: "ReLU" - bottom: "conv5" - top: "conv5" -} -layer { - name: "conv6/dw" - type: "Convolution" - bottom: "conv5" - top: "conv6/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 256 - pad: 1 - kernel_size: 3 - stride: 2 - group: 256 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv6/dw/relu" - type: "ReLU" - bottom: "conv6/dw" - top: "conv6/dw" -} -layer { - name: "conv6" - type: "Convolution" - bottom: "conv6/dw" - top: "conv6" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv6/relu" - type: "ReLU" - bottom: "conv6" - top: "conv6" -} -layer { - name: "conv7/dw" - type: "Convolution" - bottom: "conv6" - top: "conv7/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - pad: 1 - kernel_size: 3 - group: 512 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv7/dw/relu" - type: "ReLU" - bottom: "conv7/dw" - top: "conv7/dw" -} -layer { - name: "conv7" - type: "Convolution" - bottom: "conv7/dw" - top: "conv7" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv7/relu" - type: "ReLU" - bottom: "conv7" - top: "conv7" -} -layer { - name: "conv8/dw" - type: "Convolution" - bottom: "conv7" - top: "conv8/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - pad: 1 - kernel_size: 3 - group: 512 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv8/dw/relu" - type: "ReLU" - bottom: "conv8/dw" - top: "conv8/dw" -} -layer { - name: "conv8" - type: "Convolution" - bottom: "conv8/dw" - top: "conv8" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv8/relu" - type: "ReLU" - bottom: "conv8" - top: "conv8" -} -layer { - name: "conv9/dw" - type: "Convolution" - bottom: "conv8" - top: "conv9/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - pad: 1 - kernel_size: 3 - group: 512 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv9/dw/relu" - type: "ReLU" - bottom: "conv9/dw" - top: "conv9/dw" -} -layer { - name: "conv9" - type: "Convolution" - bottom: "conv9/dw" - top: "conv9" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv9/relu" - type: "ReLU" - bottom: "conv9" - top: "conv9" -} -layer { - name: "conv10/dw" - type: "Convolution" - bottom: "conv9" - top: "conv10/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - pad: 1 - kernel_size: 3 - group: 512 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv10/dw/relu" - type: "ReLU" - bottom: "conv10/dw" - top: "conv10/dw" -} -layer { - name: "conv10" - type: "Convolution" - bottom: "conv10/dw" - top: "conv10" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv10/relu" - type: "ReLU" - bottom: "conv10" - top: "conv10" -} -layer { - name: "conv11/dw" - type: "Convolution" - bottom: "conv10" - top: "conv11/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - pad: 1 - kernel_size: 3 - group: 512 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv11/dw/relu" - type: "ReLU" - bottom: "conv11/dw" - top: "conv11/dw" -} -layer { - name: "conv11" - type: "Convolution" - bottom: "conv11/dw" - top: "conv11" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv11/relu" - type: "ReLU" - bottom: "conv11" - top: "conv11" -} -layer { - name: "conv12/dw" - type: "Convolution" - bottom: "conv11" - top: "conv12/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - pad: 1 - kernel_size: 3 - stride: 2 - group: 512 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv12/dw/relu" - type: "ReLU" - bottom: "conv12/dw" - top: "conv12/dw" -} -layer { - name: "conv12" - type: "Convolution" - bottom: "conv12/dw" - top: "conv12" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 1024 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv12/relu" - type: "ReLU" - bottom: "conv12" - top: "conv12" -} -layer { - name: "conv13/dw" - type: "Convolution" - bottom: "conv12" - top: "conv13/dw" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 1024 - pad: 1 - kernel_size: 3 - group: 1024 - engine: CAFFE - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv13/dw/relu" - type: "ReLU" - bottom: "conv13/dw" - top: "conv13/dw" -} -layer { - name: "conv13" - type: "Convolution" - bottom: "conv13/dw" - top: "conv13" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 1024 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv13/relu" - type: "ReLU" - bottom: "conv13" - top: "conv13" -} -layer { - name: "conv14_1" - type: "Convolution" - bottom: "conv13" - top: "conv14_1" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 256 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv14_1/relu" - type: "ReLU" - bottom: "conv14_1" - top: "conv14_1" -} -layer { - name: "conv14_2" - type: "Convolution" - bottom: "conv14_1" - top: "conv14_2" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 512 - pad: 1 - kernel_size: 3 - stride: 2 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv14_2/relu" - type: "ReLU" - bottom: "conv14_2" - top: "conv14_2" -} -layer { - name: "conv15_1" - type: "Convolution" - bottom: "conv14_2" - top: "conv15_1" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 128 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv15_1/relu" - type: "ReLU" - bottom: "conv15_1" - top: "conv15_1" -} -layer { - name: "conv15_2" - type: "Convolution" - bottom: "conv15_1" - top: "conv15_2" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 256 - pad: 1 - kernel_size: 3 - stride: 2 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv15_2/relu" - type: "ReLU" - bottom: "conv15_2" - top: "conv15_2" -} -layer { - name: "conv16_1" - type: "Convolution" - bottom: "conv15_2" - top: "conv16_1" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 128 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv16_1/relu" - type: "ReLU" - bottom: "conv16_1" - top: "conv16_1" -} -layer { - name: "conv16_2" - type: "Convolution" - bottom: "conv16_1" - top: "conv16_2" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 256 - pad: 1 - kernel_size: 3 - stride: 2 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv16_2/relu" - type: "ReLU" - bottom: "conv16_2" - top: "conv16_2" -} -layer { - name: "conv17_1" - type: "Convolution" - bottom: "conv16_2" - top: "conv17_1" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 64 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv17_1/relu" - type: "ReLU" - bottom: "conv17_1" - top: "conv17_1" -} -layer { - name: "conv17_2" - type: "Convolution" - bottom: "conv17_1" - top: "conv17_2" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 128 - pad: 1 - kernel_size: 3 - stride: 2 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv17_2/relu" - type: "ReLU" - bottom: "conv17_2" - top: "conv17_2" -} -layer { - name: "conv11_mbox_loc" - type: "Convolution" - bottom: "conv11" - top: "conv11_mbox_loc" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 12 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv11_mbox_loc_perm" - type: "Permute" - bottom: "conv11_mbox_loc" - top: "conv11_mbox_loc_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv11_mbox_loc_flat" - type: "Flatten" - bottom: "conv11_mbox_loc_perm" - top: "conv11_mbox_loc_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv11_mbox_conf" - type: "Convolution" - bottom: "conv11" - top: "conv11_mbox_conf" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 63 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv11_mbox_conf_perm" - type: "Permute" - bottom: "conv11_mbox_conf" - top: "conv11_mbox_conf_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv11_mbox_conf_flat" - type: "Flatten" - bottom: "conv11_mbox_conf_perm" - top: "conv11_mbox_conf_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv11_mbox_priorbox" - type: "PriorBox" - bottom: "conv11" - bottom: "data" - top: "conv11_mbox_priorbox" - prior_box_param { - min_size: 60.0 - aspect_ratio: 2.0 - flip: true - clip: false - variance: 0.1 - variance: 0.1 - variance: 0.2 - variance: 0.2 - offset: 0.5 - } -} -layer { - name: "conv13_mbox_loc" - type: "Convolution" - bottom: "conv13" - top: "conv13_mbox_loc" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 24 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv13_mbox_loc_perm" - type: "Permute" - bottom: "conv13_mbox_loc" - top: "conv13_mbox_loc_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv13_mbox_loc_flat" - type: "Flatten" - bottom: "conv13_mbox_loc_perm" - top: "conv13_mbox_loc_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv13_mbox_conf" - type: "Convolution" - bottom: "conv13" - top: "conv13_mbox_conf" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 126 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv13_mbox_conf_perm" - type: "Permute" - bottom: "conv13_mbox_conf" - top: "conv13_mbox_conf_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv13_mbox_conf_flat" - type: "Flatten" - bottom: "conv13_mbox_conf_perm" - top: "conv13_mbox_conf_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv13_mbox_priorbox" - type: "PriorBox" - bottom: "conv13" - bottom: "data" - top: "conv13_mbox_priorbox" - prior_box_param { - min_size: 105.0 - max_size: 150.0 - aspect_ratio: 2.0 - aspect_ratio: 3.0 - flip: true - clip: false - variance: 0.1 - variance: 0.1 - variance: 0.2 - variance: 0.2 - offset: 0.5 - } -} -layer { - name: "conv14_2_mbox_loc" - type: "Convolution" - bottom: "conv14_2" - top: "conv14_2_mbox_loc" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 24 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv14_2_mbox_loc_perm" - type: "Permute" - bottom: "conv14_2_mbox_loc" - top: "conv14_2_mbox_loc_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv14_2_mbox_loc_flat" - type: "Flatten" - bottom: "conv14_2_mbox_loc_perm" - top: "conv14_2_mbox_loc_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv14_2_mbox_conf" - type: "Convolution" - bottom: "conv14_2" - top: "conv14_2_mbox_conf" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 126 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv14_2_mbox_conf_perm" - type: "Permute" - bottom: "conv14_2_mbox_conf" - top: "conv14_2_mbox_conf_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv14_2_mbox_conf_flat" - type: "Flatten" - bottom: "conv14_2_mbox_conf_perm" - top: "conv14_2_mbox_conf_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv14_2_mbox_priorbox" - type: "PriorBox" - bottom: "conv14_2" - bottom: "data" - top: "conv14_2_mbox_priorbox" - prior_box_param { - min_size: 150.0 - max_size: 195.0 - aspect_ratio: 2.0 - aspect_ratio: 3.0 - flip: true - clip: false - variance: 0.1 - variance: 0.1 - variance: 0.2 - variance: 0.2 - offset: 0.5 - } -} -layer { - name: "conv15_2_mbox_loc" - type: "Convolution" - bottom: "conv15_2" - top: "conv15_2_mbox_loc" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 24 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv15_2_mbox_loc_perm" - type: "Permute" - bottom: "conv15_2_mbox_loc" - top: "conv15_2_mbox_loc_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv15_2_mbox_loc_flat" - type: "Flatten" - bottom: "conv15_2_mbox_loc_perm" - top: "conv15_2_mbox_loc_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv15_2_mbox_conf" - type: "Convolution" - bottom: "conv15_2" - top: "conv15_2_mbox_conf" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 126 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv15_2_mbox_conf_perm" - type: "Permute" - bottom: "conv15_2_mbox_conf" - top: "conv15_2_mbox_conf_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv15_2_mbox_conf_flat" - type: "Flatten" - bottom: "conv15_2_mbox_conf_perm" - top: "conv15_2_mbox_conf_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv15_2_mbox_priorbox" - type: "PriorBox" - bottom: "conv15_2" - bottom: "data" - top: "conv15_2_mbox_priorbox" - prior_box_param { - min_size: 195.0 - max_size: 240.0 - aspect_ratio: 2.0 - aspect_ratio: 3.0 - flip: true - clip: false - variance: 0.1 - variance: 0.1 - variance: 0.2 - variance: 0.2 - offset: 0.5 - } -} -layer { - name: "conv16_2_mbox_loc" - type: "Convolution" - bottom: "conv16_2" - top: "conv16_2_mbox_loc" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 24 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv16_2_mbox_loc_perm" - type: "Permute" - bottom: "conv16_2_mbox_loc" - top: "conv16_2_mbox_loc_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv16_2_mbox_loc_flat" - type: "Flatten" - bottom: "conv16_2_mbox_loc_perm" - top: "conv16_2_mbox_loc_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv16_2_mbox_conf" - type: "Convolution" - bottom: "conv16_2" - top: "conv16_2_mbox_conf" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 126 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv16_2_mbox_conf_perm" - type: "Permute" - bottom: "conv16_2_mbox_conf" - top: "conv16_2_mbox_conf_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv16_2_mbox_conf_flat" - type: "Flatten" - bottom: "conv16_2_mbox_conf_perm" - top: "conv16_2_mbox_conf_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv16_2_mbox_priorbox" - type: "PriorBox" - bottom: "conv16_2" - bottom: "data" - top: "conv16_2_mbox_priorbox" - prior_box_param { - min_size: 240.0 - max_size: 285.0 - aspect_ratio: 2.0 - aspect_ratio: 3.0 - flip: true - clip: false - variance: 0.1 - variance: 0.1 - variance: 0.2 - variance: 0.2 - offset: 0.5 - } -} -layer { - name: "conv17_2_mbox_loc" - type: "Convolution" - bottom: "conv17_2" - top: "conv17_2_mbox_loc" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 24 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv17_2_mbox_loc_perm" - type: "Permute" - bottom: "conv17_2_mbox_loc" - top: "conv17_2_mbox_loc_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv17_2_mbox_loc_flat" - type: "Flatten" - bottom: "conv17_2_mbox_loc_perm" - top: "conv17_2_mbox_loc_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv17_2_mbox_conf" - type: "Convolution" - bottom: "conv17_2" - top: "conv17_2_mbox_conf" - param { - lr_mult: 1.0 - decay_mult: 1.0 - } - param { - lr_mult: 2.0 - decay_mult: 0.0 - } - convolution_param { - num_output: 126 - kernel_size: 1 - weight_filler { - type: "msra" - } - bias_filler { - type: "constant" - value: 0.0 - } - } -} -layer { - name: "conv17_2_mbox_conf_perm" - type: "Permute" - bottom: "conv17_2_mbox_conf" - top: "conv17_2_mbox_conf_perm" - permute_param { - order: 0 - order: 2 - order: 3 - order: 1 - } -} -layer { - name: "conv17_2_mbox_conf_flat" - type: "Flatten" - bottom: "conv17_2_mbox_conf_perm" - top: "conv17_2_mbox_conf_flat" - flatten_param { - axis: 1 - } -} -layer { - name: "conv17_2_mbox_priorbox" - type: "PriorBox" - bottom: "conv17_2" - bottom: "data" - top: "conv17_2_mbox_priorbox" - prior_box_param { - min_size: 285.0 - max_size: 300.0 - aspect_ratio: 2.0 - aspect_ratio: 3.0 - flip: true - clip: false - variance: 0.1 - variance: 0.1 - variance: 0.2 - variance: 0.2 - offset: 0.5 - } -} -layer { - name: "mbox_loc" - type: "Concat" - bottom: "conv11_mbox_loc_flat" - bottom: "conv13_mbox_loc_flat" - bottom: "conv14_2_mbox_loc_flat" - bottom: "conv15_2_mbox_loc_flat" - bottom: "conv16_2_mbox_loc_flat" - bottom: "conv17_2_mbox_loc_flat" - top: "mbox_loc" - concat_param { - axis: 1 - } -} -layer { - name: "mbox_conf" - type: "Concat" - bottom: "conv11_mbox_conf_flat" - bottom: "conv13_mbox_conf_flat" - bottom: "conv14_2_mbox_conf_flat" - bottom: "conv15_2_mbox_conf_flat" - bottom: "conv16_2_mbox_conf_flat" - bottom: "conv17_2_mbox_conf_flat" - top: "mbox_conf" - concat_param { - axis: 1 - } -} -layer { - name: "mbox_priorbox" - type: "Concat" - bottom: "conv11_mbox_priorbox" - bottom: "conv13_mbox_priorbox" - bottom: "conv14_2_mbox_priorbox" - bottom: "conv15_2_mbox_priorbox" - bottom: "conv16_2_mbox_priorbox" - bottom: "conv17_2_mbox_priorbox" - top: "mbox_priorbox" - concat_param { - axis: 2 - } -} -layer { - name: "mbox_conf_reshape" - type: "Reshape" - bottom: "mbox_conf" - top: "mbox_conf_reshape" - reshape_param { - shape { - dim: 0 - dim: -1 - dim: 21 - } - } -} -layer { - name: "mbox_conf_softmax" - type: "Softmax" - bottom: "mbox_conf_reshape" - top: "mbox_conf_softmax" - softmax_param { - axis: 2 - } -} -layer { - name: "mbox_conf_flatten" - type: "Flatten" - bottom: "mbox_conf_softmax" - top: "mbox_conf_flatten" - flatten_param { - axis: 1 - } -} -layer { - name: "detection_out" - type: "DetectionOutput" - bottom: "mbox_loc" - bottom: "mbox_conf_flatten" - bottom: "mbox_priorbox" - top: "detection_out" - include { - phase: TEST - } - detection_output_param { - num_classes: 21 - share_location: true - background_label_id: 0 - nms_param { - nms_threshold: 0.45 - top_k: 100 - } - code_type: CENTER_SIZE - keep_top_k: 100 - confidence_threshold: 0.25 - } -} diff --git a/README.md b/README.md deleted file mode 100644 index 5bcc2a7..0000000 --- a/README.md +++ /dev/null @@ -1,116 +0,0 @@ - -# Crowd Monitoring and Management - -Crowd monitoring and management using real-time data from IP camera and Laptop camera footage which aims to provide users with insights into the crowd density at various locations espicially at local market places , shops ,malls. This helps users make informed decisions about visiting places based on the level of crowdiness. - -## Table of Contents - -- [Overview](#overview) -- [Features](#features) -- [Installation](#installation) -- [Usage](#usage) -- [Data Collection](#data-collection) -- [UI and Visualization](#ui-and-visualization) -- [Server-Side Functionality](#server-side-functionality) -- [Contributing](#contributing) -- [License](#license) - - - (![Web Development Frameworks](https://drive.google.com/uc?export=view&id=1B_glRXdw3XcSgxc8muE5WRl48OoObYpY) - -) - - - - - - - -## Overview - -The goal of this project is to track and manage crowd density in real-time using CCTV footage. The system detects the number of people at a location, provides an option to input coordinates, and displays the crowd data on a map. It also shows peak and average crowd levels, using color coding to indicate crowd intensity. - -## Features - -- Real-time detection of crowd density using IP camera and laptop camera footage(Prototype) -- Input of coordinates for location-specific monitoring -- Display of crowd data on a map with color coding (red for high crowd, yellow for low crowd) -- Calculation and display of `max_crowd`, `average_crowd`, and `preffered_shop` -- UI enhancements for a user-friendly experience - -## Installation - -To set up the project, clone the repository and install the required dependencies. - -```bash -git clone https://github.com/erenyeager101/Crowd_monitoring.git -cd Crowd_monitoring -``` - -Ensure you have all dependencies installed by running: - -```bash -dependencies.bat -``` - -## Usage - -To start the application, run the main script in the root directory: - -```bash -start.bat -``` - -Access the web interface at `http://localhost:3000` and follow the on-screen instructions to view and interact with the crowd data. - -## Data Collection - -The system uses IP camera on android device or laptop camera footage to detect the number of people at a specific location. This data, along with coordinates and IP address, is sent to the server to update the map with the crowd information. - -## UI and Visualization - -The project includes a visually appealing and user-friendly interface. The map visualization helps users easily identify crowded areas and make decisions accordingly. - -```python -import matplotlib.pyplot as plt -import seaborn as sns - - -plt.figure(figsize=(10, 6)) -sns.barplot(x=locations, y=crowd_levels) -plt.xlabel("Locations") -plt.ylabel("Crowd Levels") -plt.show() -``` - -## Server-Side Functionality - -The server processes the incoming data, updates the crowd information on the map, and calculates the `max_crowd`, `average_crowd`, and `preffered_shop` values. It also provides real-time updates to the UI. - -## Contributing - -Contributions are welcome! Please create a pull request or raise an issue to discuss your ideas. Ensure that your contributions follow the project's coding standards and guidelines. - -## License - -This project is licensed under the MIT License - see the LICENSE file for details. - -## Additional Setup Instructions - -1. **Dependencies Installation**: - - All requirements are added in the `dependencies.bat` file. To install all dependencies, simply run this `.bat` file in the terminal. - - After running the `dependencies.bat` file, add your own IP address in the `detection.py` file. To find the IP address, install the "IP Camera" app from the Play Store. Once the server starts on the IP Camera app, the IP address will be displayed. - -2. **Running the Project**: - - To run the project, navigate to the project directory in the terminal and run the command: - ```bash - start.bat - ``` - - Ensure that the IP Camera server is started on your mobile device before running the project. - - Point the camera to a crowd to count the number of people. -3. **Current progress and issues faced** - -We tried to deploy this project but due to lack of resources we cant although we improved the UI/UX of the website pretty much but due to time congestions we couldnt -we have attached the deployment of our sample frontend of how this project would look like in future -`https://vite-woad-two-83.vercel.app/` - - diff --git a/Screenshot 2024-08-02 122716.png b/Screenshot 2024-08-02 122716.png deleted file mode 100644 index 1e18b5f..0000000 Binary files a/Screenshot 2024-08-02 122716.png and /dev/null differ diff --git a/build/asset-manifest.json b/build/asset-manifest.json deleted file mode 100644 index ca58782..0000000 --- a/build/asset-manifest.json +++ /dev/null @@ -1,15 +0,0 @@ -{ - "files": { - "main.css": "/static/css/main.7ba0c059.css", - "main.js": "/static/js/main.8db91043.js", - "static/js/453.338789e3.chunk.js": "/static/js/453.338789e3.chunk.js", - "index.html": "/index.html", - "main.7ba0c059.css.map": "/static/css/main.7ba0c059.css.map", - "main.8db91043.js.map": "/static/js/main.8db91043.js.map", - "453.338789e3.chunk.js.map": "/static/js/453.338789e3.chunk.js.map" - }, - "entrypoints": [ - "static/css/main.7ba0c059.css", - "static/js/main.8db91043.js" - ] -} \ No newline at end of file diff --git a/build/favicon.ico b/build/favicon.ico deleted file mode 100644 index a11777c..0000000 Binary files a/build/favicon.ico and /dev/null differ diff --git a/build/index.html b/build/index.html deleted file mode 100644 index 46cb5f6..0000000 --- a/build/index.html +++ /dev/null @@ -1,22 +0,0 @@ - - - - - -