Skip to content

Commit

Permalink
File extension fixed. Lower case in file name fixed. Distances Fixed.
Browse files Browse the repository at this point in the history
  • Loading branch information
antoniocavalcante committed Nov 18, 2019
1 parent 92d39f1 commit a735e07
Show file tree
Hide file tree
Showing 28 changed files with 107 additions and 20,439 deletions.
2 changes: 0 additions & 2 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -150,5 +150,3 @@ venv.bak/
.dmypy.json
dmypy.json

# .sh
run.sh
28 changes: 16 additions & 12 deletions Dockerfile
Original file line number Diff line number Diff line change
@@ -1,30 +1,34 @@
FROM ubuntu:latest
USER root
RUN apt-get update -y
RUN apt-get install -y apt-utils
RUN apt-get install -y python3-dev python3-pip build-essential
RUN apt-get install -y python-dev python-pip

# Install nodemon
RUN apt-get install -y nodejs npm
RUN apt-get update && apt-get install -y \
python3-dev \
python3-pip \
build-essential \
python-dev \
python-pip \
nodejs \
npm

RUN npm i -g nodemon

ENV TZ=America/Los_Angeles
RUN ln -snf /usr/share/zoneinfo/$TZ /etc/localtime && echo $TZ > /etc/timezone

# dependancies
RUN apt-get install -y default-jdk
RUN apt-get install -y python-tk
RUN apt-get install -y python3-tk
RUN apt install -y gunicorn
RUN apt install -y python-numpy
RUN apt-get update && apt-get install -y \
default-jdk \
python-tk \
python3-tk \
gunicorn \
python-numpy

# copy source
COPY . /app
ENV HOME=/app
RUN chmod a+rwx app
WORKDIR /app
RUN mkdir workspace
RUN mkdir -p workspace
RUN chmod a+rwx workspace

RUN pip3 install -r requirements.txt
Expand Down
2 changes: 1 addition & 1 deletion compose.sh
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,6 @@ echo "export COMPOSE_PROJECT_NAME=mustache" >> run.sh
echo "export MUSTACHE_WORKSPACE=$1" >> run.sh
echo "docker-compose up -d" >> run.sh
echo "sleep 3" >> run.sh
# echo "xdg-open http://127.0.0.01:5000" >> run.sh
echo "xdg-open http://127.0.0.01:5000" >> run.sh

docker-compose build --compress
2 changes: 0 additions & 2 deletions docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@ services:
volumes:
- '$MUSTACHE_WORKSPACE:/app/workspace'
- '.:/usr/src/app:ro'
- '.:/app'
ports:
- '5000:5000'
links:
Expand All @@ -27,7 +26,6 @@ services:
volumes:
- '$MUSTACHE_WORKSPACE:/app/workspace'
- '.:/usr/src/app:ro'
- '.:/app'

redis:
image: redis
Expand Down
17 changes: 8 additions & 9 deletions mustache/__init__.py
Original file line number Diff line number Diff line change
@@ -1,13 +1,7 @@
import datetime as dt
import uuid

from flask import Flask, request, Config
from celery import Celery
from flask import Config, Flask, request

from .util.assests import assets
from .views.api import api
from .views.dashboard import dashboard
from .views.home import home
import uuid
import datetime as dt

app = Flask(__name__)
app.config.from_json("settings.json")
Expand All @@ -23,7 +17,12 @@ def format_datetime(value):
celery = Celery(app.name, broker=app.config['CELERY_BROKER_URL'])
celery.conf.update(app.config)

from .views.dashboard import dashboard
from .views.home import home
from .views.api import api

app.register_blueprint(home, url_prefix="/")
app.register_blueprint(dashboard, url_prefix="/dashboard")
app.register_blueprint(api)

from .util.assests import assets
Binary file modified mustache/resources/IHDBSCAN.jar
Binary file not shown.
2 changes: 1 addition & 1 deletion mustache/resources/hierarchies.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@

import os

# import pyximport; pyximport.install()
import pyximport; pyximport.install()

import hierarchy
from hierarchy_tree import HierarchyTree
Expand Down
1 change: 1 addition & 0 deletions mustache/resources/run.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ FILE_NAME=$(basename "$1")
java -jar -Xmx12G IHDBSCAN.jar file=$8/$FILE_NAME minPts=$2 minClSize=$3 filter=$4 output=$5 dist_function=$6 compact=$7 separator=","

mv $8/visualization/*.mst $8/msts
rm $8/visualization/*.tree

# Runs the meta-clustering.
python hierarchies.py "$8/visualization" $FILE_NAME 2 $MPTS
Expand Down
2 changes: 1 addition & 1 deletion mustache/settings.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"WORKSPACE": "/app/workspace",
"DEBUG": true,
"DEBUG": false,
"CELERY_BROKER_URL": "redis://redis/0",
"CELERY_RESULT_BACKEND": "redis://redis/0"
}
37 changes: 1 addition & 36 deletions mustache/static/css/dashboard/dashboard.css
Original file line number Diff line number Diff line change
Expand Up @@ -139,10 +139,6 @@ div.tooltip {
display: inline;
}

#chart-circle {
display: inline;
}

body {
overflow: hidden;
}
Expand Down Expand Up @@ -235,7 +231,7 @@ html {
}

.grouper>.row {
overflow-y: scroll;
overflow-x: scroll;
white-space: nowrap;
}

Expand Down Expand Up @@ -566,34 +562,3 @@ html {
.about-header {
font-size: 24px;
}

.d3-tip {
line-height: 1;
font: 14px sans-serif;
padding: 12px;
background: rgba(0, 0, 0, 0.8);
color: rgb(185, 185, 185);
border-radius: 2px;
box-shadow: 0 0 11px 0px black;
z-index: 10000;
}

/* Creates a small triangle extender for the tooltip */
.d3-tip:after {
box-sizing: border-box;
display: inline;
font-size: 10px;
width: 100%;
line-height: 1;
color: rgba(0, 0, 0, 0.8);
content: "\25BC";
position: absolute;
text-align: center;
}

.d3-tip.n:after {
margin: -1px 0 0 0;
top: 100%;
left: 0;
z-index: -1;
}
39 changes: 2 additions & 37 deletions mustache/static/gen/dashboard.css
Original file line number Diff line number Diff line change
Expand Up @@ -8131,10 +8131,6 @@ div.tooltip {
display: inline;
}

#chart-circle {
display: inline;
}

body {
overflow: hidden;
}
Expand Down Expand Up @@ -8216,7 +8212,7 @@ html {
}

.side-logo-newcastle {
width: 80%;
width: 90%;
margin: 0 5%;
margin-bottom: 10%;
}
Expand All @@ -8227,7 +8223,7 @@ html {
}

.grouper>.row {
overflow-y: scroll;
overflow-x: scroll;
white-space: nowrap;
}

Expand Down Expand Up @@ -8558,37 +8554,6 @@ html {
.about-header {
font-size: 24px;
}

.d3-tip {
line-height: 1;
font: 14px sans-serif;
padding: 12px;
background: rgba(0, 0, 0, 0.8);
color: rgb(185, 185, 185);
border-radius: 2px;
box-shadow: 0 0 11px 0px black;
z-index: 10000;
}

/* Creates a small triangle extender for the tooltip */
.d3-tip:after {
box-sizing: border-box;
display: inline;
font-size: 10px;
width: 100%;
line-height: 1;
color: rgba(0, 0, 0, 0.8);
content: "\25BC";
position: absolute;
text-align: center;
}

.d3-tip.n:after {
margin: -1px 0 0 0;
top: 100%;
left: 0;
z-index: -1;
}
#wrapper .sidebar {
background-color: #2B333E;
}
Expand Down
176 changes: 11 additions & 165 deletions mustache/static/gen/dashboard.js

Large diffs are not rendered by default.

40 changes: 2 additions & 38 deletions mustache/static/gen/home.css
Original file line number Diff line number Diff line change
Expand Up @@ -15342,7 +15342,6 @@ body {
width: 100%;
height: 2px;
} */

.lds-rng {
display: inline-block;
position: relative;
Expand Down Expand Up @@ -15659,10 +15658,6 @@ div.tooltip {
display: inline;
}

#chart-circle {
display: inline;
}

body {
overflow: hidden;
}
Expand Down Expand Up @@ -15744,7 +15739,7 @@ html {
}

.side-logo-newcastle {
width: 80%;
width: 90%;
margin: 0 5%;
margin-bottom: 10%;
}
Expand All @@ -15755,7 +15750,7 @@ html {
}

.grouper>.row {
overflow-y: scroll;
overflow-x: scroll;
white-space: nowrap;
}

Expand Down Expand Up @@ -16086,37 +16081,6 @@ html {
.about-header {
font-size: 24px;
}

.d3-tip {
line-height: 1;
font: 14px sans-serif;
padding: 12px;
background: rgba(0, 0, 0, 0.8);
color: rgb(185, 185, 185);
border-radius: 2px;
box-shadow: 0 0 11px 0px black;
z-index: 10000;
}

/* Creates a small triangle extender for the tooltip */
.d3-tip:after {
box-sizing: border-box;
display: inline;
font-size: 10px;
width: 100%;
line-height: 1;
color: rgba(0, 0, 0, 0.8);
content: "\25BC";
position: absolute;
text-align: center;
}

.d3-tip.n:after {
margin: -1px 0 0 0;
top: 100%;
left: 0;
z-index: -1;
}
@font-face {
font-family: LogoFont;
src: url(../css/roboto-condensed/RobotoCondensed-Bold.ttf);
Expand Down
Loading

0 comments on commit a735e07

Please sign in to comment.