<reponame>Code-and-Response/ISAC-SIMO-Repo-2
from django.urls import path
from . import views
from django.conf import settings
from django.conf.urls.static import static

urlpatterns = [
    # Image & Image Files
    path('image', views.images, name="images"),
    path('image/add', views.addImage, name="images.add"),
    path('image/test', views.testImage, name="images.test"),
    path('image/update/<int:id>', views.updateImage, name="images.update"),
    path('image/delete/<int:id>', views.deleteImage, name="images.delete"),
    path('image/send/to/retrain/<int:id>', views.retrainImage, name="images.retrain"),
    path('image/image_file/delete/<int:id>', views.deleteImageFile, name="images.image_file.delete"),
    path('image/image_file/retest/<int:id>', views.retestImageFile, name="images.image_file.retest"),
    path('image/image_file/verify/<int:id>', views.verifyImageFile, name="images.image_file.verify"),

    # Watson
    # -----------
    path('watson/classifier', views.watsonClassifierList, name="watson.classifier.list"),
    path('watson/classifier/order/<int:id>', views.watsonClassifierOrder, name="watson.classifier.order"),
    path('watson/classifier/create', views.watsonClassifierCreate, name="watson.classifier.create"),
    path('watson/classifier/delete/<int:id>', views.watsonClassifierDelete, name="watson.classifier.delete"),
    path('watson/classifier/edit/<int:id>', views.watsonClassifierEdit, name="watson.classifier.edit"),
    path('watson/classifier/test/<int:id>', views.watsonClassifierTest, name="watson.classifier.test"),
    path('watson/classifier/detail', views.watsonClassifier, name="watson.classifier"),
    path('watson/classifier/train', views.watsonTrain, name="watson.train"), # train or re-train
    # -----------
    path('watson/object/list', views.watsonObjectList, name="watson.object.list"),
    path('watson/object/create', views.watsonObjectCreate, name="watson.object.create"),
    path('watson/object/delete/<int:id>', views.watsonObjectDelete, name="watson.object.delete"),
    path('watson/object/verify/<int:id>', views.watsonObjectVerify, name="watson.object.verify"),
    path('watson/object/wishlist/<int:id>', views.watsonObjectWishlist, name="watson.object.wishlist"),
    path('watson/object/detail', views.watsonObject, name="watson.object"), # fetch from ibm details

    # Offline Model
    # ---------------
    path('offline_model', views.offlineModel, name="offline.model.list"),
    path('offline_model/create', views.offlineModelCreate, name="offline.model.create"),
    path('offline_model/edit/<int:id>', views.offlineModelEdit, name="offline.model.edit"),
    path('offline_model/delete/<int:id>', views.offlineModelDelete, name="offline.model.delete"),
    path('offline_model/test/<int:id>', views.offlineModelTest, name="offline.model.test"),
    path('offline_model/dependencies/<int:id>', views.offlineModelDependencies, name="offline.model.dependencies"),
    path('offline_model/readme.md', views.offlineModelReadme, name="offline.model.readme"),

    # Other Misc. Actions
    path('misc/clean/temp', views.cleanTemp, name="watson.cleantemp"),
    path('misc/clean/temp/streetview', views.cleanTempStreetView, name="watson.cleantempstreetview"),
    path('misc/count/images', views.countImage, name="watson.countimage"),
    path('misc/dump/images', views.dumpImage, name="watson.dumpimage"),#dump json of image+image_file models

    # Terminal
    path('terminal', views.terminal, name="terminal"),
    # File Upload
    path('file_upload', views.fileUpload, name="file_upload"),
    path('file_upload/delete/<int:id>', views.fileUploadDelete, name="file_upload.delete")
]

if settings.DEBUG:
    urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
from django.urls import path
from . import views
from django.conf import settings
from django.conf.urls.static import static

urlpatterns = [
    # Image & Image Files
    path('image', views.images, name="images"),
    path('image/add', views.addImage, name="images.add"),
    path('image/test', views.testImage, name="images.test"),
    path('image/update/<int:id>', views.updateImage, name="images.update"),
    path('image/delete/<int:id>', views.deleteImage, name="images.delete"),
    path('image/send/to/retrain/<int:id>', views.retrainImage, name="images.retrain"),
    path('image/image_file/delete/<int:id>', views.deleteImageFile, name="images.image_file.delete"),
    path('image/image_file/retest/<int:id>', views.retestImageFile, name="images.image_file.retest"),
    path('image/image_file/verify/<int:id>', views.verifyImageFile, name="images.image_file.verify"),

    # Watson
    # -----------
    path('watson/classifier', views.watsonClassifierList, name="watson.classifier.list"),
    path('watson/classifier/order/<int:id>', views.watsonClassifierOrder, name="watson.classifier.order"),
    path('watson/classifier/create', views.watsonClassifierCreate, name="watson.classifier.create"),
    path('watson/classifier/delete/<int:id>', views.watsonClassifierDelete, name="watson.classifier.delete"),
    path('watson/classifier/edit/<int:id>', views.watsonClassifierEdit, name="watson.classifier.edit"),
    path('watson/classifier/test/<int:id>', views.watsonClassifierTest, name="watson.classifier.test"),
    path('watson/classifier/detail', views.watsonClassifier, name="watson.classifier"),
    path('watson/classifier/train', views.watsonTrain, name="watson.train"), # train or re-train
    # -----------
    path('watson/object/list', views.watsonObjectList, name="watson.object.list"),
    path('watson/object/create', views.watsonObjectCreate, name="watson.object.create"),
    path('watson/object/delete/<int:id>', views.watsonObjectDelete, name="watson.object.delete"),
    path('watson/object/verify/<int:id>', views.watsonObjectVerify, name="watson.object.verify"),
    path('watson/object/wishlist/<int:id>', views.watsonObjectWishlist, name="watson.object.wishlist"),
    path('watson/object/detail', views.watsonObject, name="watson.object"), # fetch from ibm details

    # Offline Model
    # ---------------
    path('offline_model', views.offlineModel, name="offline.model.list"),
    path('offline_model/create', views.offlineModelCreate, name="offline.model.create"),
    path('offline_model/edit/<int:id>', views.offlineModelEdit, name="offline.model.edit"),
    path('offline_model/delete/<int:id>', views.offlineModelDelete, name="offline.model.delete"),
    path('offline_model/test/<int:id>', views.offlineModelTest, name="offline.model.test"),
    path('offline_model/dependencies/<int:id>', views.offlineModelDependencies, name="offline.model.dependencies"),
    path('offline_model/readme.md', views.offlineModelReadme, name="offline.model.readme"),

    # Other Misc. Actions
    path('misc/clean/temp', views.cleanTemp, name="watson.cleantemp"),
    path('misc/clean/temp/streetview', views.cleanTempStreetView, name="watson.cleantempstreetview"),
    path('misc/count/images', views.countImage, name="watson.countimage"),
    path('misc/dump/images', views.dumpImage, name="watson.dumpimage"),#dump json of image+image_file models

    # Terminal
    path('terminal', views.terminal, name="terminal"),
    # File Upload
    path('file_upload', views.fileUpload, name="file_upload"),
    path('file_upload/delete/<int:id>', views.fileUploadDelete, name="file_upload.delete")
]

if settings.DEBUG:
    urlpatterns += static(settings.STATIC_URL, document_root=settings.STATIC_ROOT)
    urlpatterns += static(settings.MEDIA_URL, document_root=settings.MEDIA_ROOT)
# Image & Image Files # Watson # ----------- # train or re-train # ----------- # fetch from ibm details # Offline Model # --------------- # Other Misc. Actions #dump json of image+image_file models # Terminal # File Upload