This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // SPDX-License-Identifier: GPL-3.0 | |
| pragma solidity >=0.7.0 <0.9.0; | |
| contract Lottery { | |
| address public manager; | |
| address[] public players; | |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| Training script for hate content detection model | |
| """ | |
| import pandas as pd | |
| import tensorflow as tf | |
| from utils import ImageProcessor, SimpleMetalKMeans | |
| def train(): | |
| """Main training function""" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| # Installation Guide | |
| ## System Requirements | |
| ### Hardware | |
| - Apple Silicon Mac (M1/M2/M3) | |
| - Minimum 16GB RAM recommended | |
| - SSD storage recommended |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from config import PATHS, MODEL_PATH, PREDICTIONS_CSV, ADVERSARIAL_PREDICTIONS_CSV | |
| import sys | |
| import tensorflow as tf | |
| import cv2 | |
| import numpy as np | |
| import pandas as pd | |
| from tqdm import tqdm | |
| def verify_setup(): | |
| """ |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| from config import PATHS, MODEL_PATH, PREDICTIONS_CSV, ADVERSARIAL_PREDICTIONS_CSV | |
| """ | |
| Inference script for hate content detection model | |
| """ | |
| import pandas as pd | |
| from utils import ImageProcessor, SimpleMetalKMeans | |
| def run_inference(image_folder, model_path="model/kmeans_model.pkl"): |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| """ | |
| Basic Adversarial Testing Script | |
| """ | |
| import os | |
| import numpy as np | |
| import tensorflow as tf | |
| import cv2 | |
| from tqdm import tqdm | |
| import pandas as pd |
OlderNewer