Docker can slow down your code and distort your benchmarks

One of the benefits of containers over virtual machines is that you get some measure of isolation without the performance overhead or distortion of virtualization. Docker images therefore seem like a good way to get a reproducible environment for measuring CPU performance of your code. There are, however, complications. Sometimes, running under Docker can actually slow down your code and distort your performance measurements. On macOS and Windows, for example, standard Linux-based Docker containers aren’t actually running directly on the […]

Read more

Issue #130 – Shared-Private Bilingual Word Embeddings for NMT

13 May21 Issue #130 – Shared-Private Bilingual Word Embeddings for NMT Author: Akshai Ramesh, Machine Translation Scientist @ Iconic Introduction In recent years, there has been a significant amount of research to improve the representation learning of neural machine translation (NMT). In today’s blog post, we will look at the work of Liu et al., 2019 who propose a novel approach called Shared-Private Bilingual Word Embeddings, to improve the word representations of NMT. Introduction A word representation is a mathematical […]

Read more

A Computer vision package that makes its easy to run Image processing

CVZone This is a Computer vision package that makes its easy to run Image processing and AI functions. At the core it uses OpenCV and Mediapipe libraries. Installation You can simply use pip to install the latest version of cvzone. pip install cvzone 60 FPS Face Detection import cvzone import cv2 cap = cv2.VideoCapture(0) detector = cvzone.FaceDetector() while True: success, img = cap.read() img, bboxs = detector.findFaces(img) print(bboxs) cv2.imshow(“Image”, img) cv2.waitKey(1) Hand Tracking Basic Code Example import cvzone import cv2 […]

Read more

A Lucid Framework for Transparent and Interpretable Machine Learning Models

lucidmode lucidmode is an open-source, low-code and lightweight Python framework for transparent and interpretable machine learning models. It has built in machine learning methods optimized for visual interpretation of some of the most relevant calculations. Installation With package manager (coming soon) Install by using pip package manager: pip install lucidmode Clone entire github project [email protected]:lucidmode/lucidmode.git and then install dependencies pip install -r requirements.txt Models Artificial Neural Network Feedforward Multilayer perceptron with backpropagation. fit: Fit model to data predict: Prediction according […]

Read more

The command line interface for Gradient

Gradient CLI Gradient is an an end-to-end MLOps platform that enables individuals and organizations to quickly develop, train, and deploy Deep Learning models. The Gradient software stack runs on any infrastructure e.g. AWS, GCP, on-premise and low-cost Paperspace GPUs. Leverage automatic versioning, distributed training, built-in graphs & metrics, hyperparameter search, GradientCI, 1-click Jupyter Notebooks, our Python SDK, and more. Key components: Notebooks: 1-click Jupyter Notebooks. Experiments: Run experiments from a web interface, CLI, SDK, or GradientCI bot. Models: Store, analyze, […]

Read more

A PostgreSQL or SQLite orm for Python

Prom An opinionated lightweight orm for PostgreSQL or SQLite. Prom has been used in both single threaded and multi-threaded environments, including environments using Greenthreads. 1 Minute Getting Started with SQLite First, install prom: $ pip install prom Set an environment variable: $ export PROM_DSN=sqlite://:memory: Start python: $ python Create a prom Orm: >>> import prom >>> >>> class Foo(prom.Orm): … table_name = “foo_table_name” … bar = prom.Field(int) … >>> Now go wild and create some Foo objects: >>> for x […]

Read more

HTTP client mocking tool for Python

HTTPretty HTTP Client mocking tool for Python created by Gabriel Falcão . It provides a full fake TCP socket module. Inspired by FakeWeb Install pip install httpretty Common Use Cases Test-driven development of API integrations Fake responses of external APIs Record and playback HTTP requests Simple Example import sure import httpretty import requests @httpretty.activate def test_httpbin(): httpretty.register_uri( httpretty.GET, “https://httpbin.org/ip”, body='{“origin”: “127.0.0.1”}’ ) response = requests.get(‘https://httpbin.org/ip’) response.json().should.equal({‘origin’: ‘127.0.0.1’}) httpretty.latest_requests().should.have.length_of(1) httpretty.last_request().should.equal(httpretty.latest_requests()[0]) httpretty.last_request().body.should.equal(‘{“origin”: “127.0.0.1”}’) checking multiple responses @httpretty.activate def test_post_bodies(): url = ‘http://httpbin.org/post’ […]

Read more

Medical image analysis framework merging ANTsPy and deep learning

ANTsPyNet A collection of deep learning architectures and applications ported to the python language and tools for basic medical image processing. Based on keras and tensorflow with cross-compatibility with our R analog ANTsRNet. Documentation page https://antsx.github.io/ANTsPyNet/. Installation Publications Nicholas J. Tustison, Talissa A. Altes, Kun Qing, Mu He, G. Wilson Miller, Brian B. Avants, Yun M. Shim, James C. Gee, John P. Mugler III, Jaime F. Mata. Image- vs. histogram-based considerations in semantic segmentation of pulmonary hyperpolarized gas images. (medrxiv) […]

Read more

A Python description of the Kinematic Bicycle Model with an animated example

Kinematic Bicycle Model A Python description of the Kinematic Bicycle Model with an animated example. Abstract A python library for the Kinematic Bicycle model. :param x: (float) vehicle’s x-coordinate :param y: (float) vehicle’s y-coordinate :param yaw: (float) vehicle’s heading [rad] :param v: (float) vehicle’s velocity in the x-axis [m/s] :param throttle: (float) vehicle’s forward speed [m/s] :param delta: (float) vehicle’s steering angle [rad] :param L: (float) vehicle’s wheelbase [m] :param max_steer: (float) vehicle’s steering limits [rad] :param c_r: (float) vehicle’s […]

Read more

Write Pythonic and Clean Code With namedtuple

Python’s collections module provides a factory function called namedtuple(), which is specially designed to make your code more Pythonic when you’re working with tuples. With namedtuple(), you can create immutable sequence types that allow you to access their values using descriptive field names and the dot notation instead of unclear integer indices. If you have some experience using Python, then you know that writing Pythonic code is a core skill for Python developers. In this tutorial, you’ll level up that […]

Read more
1 650 651 652 653 654 928