This file contains 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
"""A simple example of asyncio. This code is available from python 3.7. | |
References | |
- history of asyncio: https://asyncio-notes.readthedocs.io/en/latest/asyncio-history.html | |
- asyncio: https://docs.python.org/3/library/asyncio.html | |
- asyncio.queue: https://docs.python.org/3.7/library/asyncio-queue.html | |
- producer-consumer: https://stackoverflow.com/questions/52582685/using-asyncio-queue-for-producer-consumer-flow | |
""" | |
import asyncio |
This file contains 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
# usage: `$ make utest MODULE_NAME=fibonacci` | |
utest: | |
if [ ! -d "test" ]; then mkdir test; fi | |
pynguin --algorithm RANDOM --project_path . --output_path test --module_name ${MODULE_NAME} | |
# usage: `$ make run-utest` | |
run-utest: | |
env PYTHONPATH=. pytest test --verbose --cov . --cov-report=html --cov-report=term-missing | |
# usage: `$ make show-cov MODULE_NAME=fibonacci` |
This file contains 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
"""Genetic algorithm solver. | |
Given the following function: | |
y = f(w1:w3) = w1 / (w2 + w3) + w2 / (w1 + w3) + w3 / (w1 + w2) | |
where y=4 | |
What are the best values for the 3 weights (w1 to w3)? | |
We are going to use the genetic algorithm to optimize this function. | |
""" | |
import pygad |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
# -*- coding: utf-8 -*- | |
"""Scrap data from Naver Finance. | |
Author: | |
- Name: Jinwoo Park | |
- Email: [email protected] | |
Prerequisites: | |
pip install beautifulsoup4 | |
pip install html5lib |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains 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
#include <iostream> | |
#include <vector> | |
#include <array> | |
#include <opencv2/highgui.hpp> | |
#include <opencv2/opencv.hpp> | |
#include <onnxruntime/onnxruntime_cxx_api.h> | |
int main(int argc, const char* argv[]) { | |
std::cout << "Optimized? " << cv::useOptimized() << std::endl; |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
OlderNewer