Machine Learning Engineer / Data Scientist – SoundHound Inc. – Toronto, ON
From SoundHound Inc. – Wed, 10 Jul 2019 08:21:55 GMT – View all Toronto, ON jobs
https://www.youtube.com/watch?v=rbJ4W2r8PfA
The owner of the YouTube channel Ctrl Shift Face recently marked Slavester Stallone’s amazing visit to the legendary action movie Terminator 2, where he replaced his colleague in the workshop of Arnold Schwarzenegger. Now the neural network did the same trick with the movie “The Shining”, changing Jack Nicholson to comedian Jim Carrey.This time there are practically no artifacts in the video – thanks to the low dynamic of events in the frame. Understand that in front of us is not Jim Carrey, it is possible only on an extremely high forehead – the characteristic feature of Jack Nicholson. By the way, in the comments, the author of the video is advised to do the reverse trick and put the textured Nicholson in the comedy Ace Ventura.
submitted by /u/PlayfulConfidence
[link] [comments]
Raspberry Pi 4 doesn’t work with some USB-C chargers!
some USB-C chargers (those with “e-marked” cables) will only recognize the Pi 4 as an audio accessory and won’t charge it.
submitted by /u/makereven
[link] [comments]
Hi r/ML
I have been playing around with the chatbot from this transformer tutorial.
When I save the model, with model.save(‘m.hdf5’), I get a JSON not serializeable error.
Has anyone had any luck saving and restoring these attention-based models before?
submitted by /u/ImSeeU
[link] [comments]
Hi All, I’m a PhD student in the UK and I am currently working on a paper. I won’t go into the specifics of the problem, but I will lay out my methodology and I would love to hear your opinions. My aim is to publish in a journal related the application, not a machine learning journal. Because of this the machine learning techniques used here are, by design, not novel.
The problem boils down to imbalanced binary classification with around 15,000 data points each with 9 features, only around 600 of which belong to the minority class. We call this DataSet1. In preliminary experiments I implement steps 1 and 2 on DataSet1.
Step 1: Using Sklearn in Python: Use k-fold cross validation to compare the performance of 10 popular classifiers: SVM, Random Forest, Logistic Regression, etc. Gridsearch would be used for hyperparameter selection and the models would be scored using the area under their ROC curve (AUC).
Step 2: The best three performing classifiers would then be assessed in conjunction with sampling techniques such as under sampling, over sampling and SMOTE. Implementation of classifiers which internally incorporate sampling methods (such as balanced random forest and balanced bagging) would also be tested.
In my case the DataSet1 is time series. As this experimentation did not give good enough results, I decide to implement step 3 on DataSet1
Step 3: Reformulate the data set by having each data point also include the first λ lags (the λ previous observations) of each variable. Where λ is a natural number.
This produced DataSet2 in which each data point now contained λ*9 features. The aim was then to implement step 1 and 2 on this new data set. However, the high dimensionality combined with the large number of data points, cross validation and Gridsearch hyperparameter selection lead to these experiments having an inconveniently long run time.
To reduce the dimensionality PCA is used on the DataSet1 to produce DataSet3 in which data points are observations of the principal components required to explain 95% of the total variance. Step 3 is then implemented on DataSet3 creating DataSet4. Steps 1 and 2 can then be implemented on DataSet4. For a suitable value of λ in my case 12, this led to much more accurate classification.
Is this a good line of experimentation? Is this AUC scoring alone sufficient? Is there anything about this method that is bad practice? Are the models that I am using outdated? Any feedback would be greatly appreciated! Thanks!
submitted by /u/Bryan-Ferry
[link] [comments]
Hello, /r/MachineLearning!
I’ve been working on a SISR project lately and I’m trying to reproduce some interesting network architectures. I’m having some problems replicating this paper about Deep Recursive Residual Networks (DRRN).
I’m training a DRRN with 4 residual blocks, recursively applied 3 times each to reconstruct face images. Training usually starts smoothly but somewhere along the way the loss function explodes and all progress is lost. This seems to be an artifact of the architecture, since each filter is applied multiple times and can then sum up to a big gradient.
I’ve tried to follow the paper’s original implementation details to the maximum extent I could: I used SGD with 0.9 momentum and the max batch size I could with available VRAM (16, which is admittedly far away from the original 128), a decreasing learning rate and gradient clipping based on the current learning rate. The SGD yielded horrible results, the network diverged, so I changed it to Adam, which worked better. Still, nothing helped with the random loss function jumps.
I was just wondering if this is normal and if anyone else had this, or if perhaps this is due to some implementation error (I’m using Keras and the code is kinda messy, but I could make it available on demand). If you had this, can you share some tips on how to properly train these networks?
Thanks!
submitted by /u/abello966
[link] [comments]
Deep learning (DL) frameworks enable machine learning (ML) practitioners to build and train ML models. However, the process of deploying ML models in production to serve predictions (also known as inferences) in real time is more complex. It requires that ML practitioners build a scalable and performant model server, which can host these models and handle inference requests at scale.
Model Server for Apache MXNet (MMS) was developed to address this hurdle. MMS is a highly scalable, production-ready inference server. MMS was designed in a ML/DL framework agnostic way to host models trained in any ML/DL framework.
In this post, we showcase how you can use MMS to host a model trained using any ML/DL framework or toolkit in production. We chose Amazon SageMaker for production hosting. This PaaS solution does a lot of heavy lifting to provide infrastructure and allows you to focus on your use cases.
For this solution, we use the approach outlined in Bring your own inference code with Amazon SageMaker hosting. This post explains how you can bring your models together with all necessary dependencies, libraries, frameworks, and other components. Compile them in a single custom-built Docker container and then host them on Amazon SageMaker.
To showcase the ML/DL framework-agnostic architecture of MMS, we chose to launch a model trained with the PaddlePaddle framework into production. The steps for taking a model trained on any ML/DL framework to Amazon SageMaker using an MMS bring your own (BYO) container are illustrated in the following diagram:

As this diagram shows, you need two main components to bring your ML/DL framework to Amazon SageMaker using an MMS BYO container:
In the following sections, we describe each of the components in detail.
The MMS container is ML/DL framework agnostic. Write models in a ML/DL framework of your choice and bring it to Amazon SageMaker with an MMS BYO container to get the features of scalability and performance. We show you how to prepare a PaddlePaddle model in the following sections.
Use the Understand Sentiment example that is available and published in the examples section of the PaddlePaddle repository.
First, create a model following the instructions provided in the PaddlePaddle/book repository. Download the container and run the training using the notebook provided as part of the example. We used the Stacked Bidirectional LSTM network for training, and trained the model for 100 epochs. At the end of this training exercise, we got the following list of trained model artifacts.
These artifacts constitute a PaddlePaddle model.
You now have the model files required to host the model in production. To take this model into production with MMS, provide a custom service script that knows how to use these files. This script must also know how to pre-process the raw request coming into the server and how to post-process the responses coming out of the PaddlePaddle framework’s infer method.
Create a custom service file called paddle_sentiment_analysis.py. Here, define a class called PaddleSentimentAnalysis that contains methods to initialize the model and also defines pre-processing, post-processing, and inference methods. The skeleton of this file is as follows:
To understand the details of this custom service file, see paddle_sentiment_analysis.py. This custom service code file allows you to tell MMS what the lifecycle of each inference request should look like. It also defines how a trained model-artifact can initialize the PaddlePaddle framework.
Now that you have the trained model artifacts and the custom service file, create a model-archive that can be used to create your endpoint on Amazon SageMaker.
To load this model in Amazon SageMaker with an MMS BYO container, do the following:
Use the model-archiver tool to do this. Before you use the tool to create a .tar.gz artifact, put all the model artifacts in a separate folder, including the custom service script mentioned earlier. To ease this process, we have made all the artifacts available for you. Run the following commands:
Now you are ready to create the artifact required for hosting in Amazon SageMaker, using the model-archiver tool. The model-archiver tool is a part of the MMS toolkit. To get this tool, run these commands in a Python virtual environment because it provides isolation from the rest of the working environment.
The model-archiver tool comes preinstalled when you install mxnet-model-server.
This generates a file called sentiment.tar.gz in the /model-store directory. This file contains all the artifacts of the models and the manifest file.
You now have all the model artifacts that can be hosted on Amazon SageMaker. Next, look at how to build a container and bring it into Amazon SageMaker.
In this section, you build your own MMS-based container (also known as a BYO container) that can be hosted in Amazon SageMaker.
To help with this process, every released version of MMS comes with a corresponding MMS base CPU and GPU containers hosted on DockerHub, which can be hosted on Amazon SageMaker.
For this example, use a container tagged awsdeeplearningteam/mxnet-model-server:base-cpu-py3.6. To host the model created in the earlier section, install the PaddlePaddle and numpy packages in the container. Create a Dockerfile that extends from the base MMS image and installs the Python packages. The artifacts that you downloaded earlier come with the sample Dockerfile necessary to install required packages:
Now that you have the Dockerfile that describes your BYO container, build it:
You have the BYO container with all of the model artifacts in it, and you’re ready to launch it in Amazon SageMaker.
In this section, you create an Amazon SageMaker endpoint in the console using the artifacts created earlier. We also provide an interactive Jupyter Notebook example of creating an endpoint using the Amazon SageMaker Python SDK and AWS SDK for Python (Boto3). The notebook is available on the mxnet-model-server GitHub repository.
Before you create an Amazon SageMaker endpoint for your model, do some preparation:


Now that the model and container artifacts are uploaded to S3 and ECR, you can create the Amazon SageMaker endpoint. Complete the following steps:
First, create a model configuration.



After you create the model configuration, create an endpoint configuration.


Now we go to the final step, which is creating endpoint for users to send the inference requests to.



You have created an endpoint called “sentiment” on Amazon SageMaker with an MMS BYO container to host a model built with the PaddlePaddle DL framework.
Now test this endpoint and make sure that it can indeed serve inference requests.
Create a simple test client using the Boto3 library. Here is a small test script that sends a payload to the Amazon SageMaker endpoint and retrieves its response:
The corresponding output from running this script is as follows:
In this post, we showed you how to build and host a PaddlePaddle model on Amazon SageMaker using an MMS BYO container. This flow can be reused with minor modifications to build BYO containers serving inference traffic on Amazon SageMaker endpoints with MMS for models built using many ML/DL frameworks, not just PaddlePaddle.
For a more interactive example to deploy the above PaddlePaddle model into Amazon SageMaker using MMS, see Amazon SageMaker Examples. To learn more about the MMS project, see the mxnet-model-server GitHub repository.
Vamshidhar Dantu is a Software Developer with AWS Deep Learning. He focuses on building scalable and easily deployable deep learning systems. In his spare time, he enjoy spending time with family and playing badminton.
Denis Davydenko is an Engineering Manager with AWS Deep Learning. He focuses on building Deep Learning tools that enable developers and scientists to build intelligent applications. In his spare time he enjoys spending time with his family, playing poker and video games.
| |
Gradio is a library I built at Stanford to easily share models with non-coders, something I had to do often in research collaborations. It’s become adopted at Stanford and I wanted to share it with the community, and would love to hear your thoughts! With only a few lines of code, you can easily share your machine learning models by automatically creating a simple drag-and-drop interface for any collaborator to use. https://i.redd.it/zgb2b2dq5c931.png You can even host the model on GradioHub, see here and here for some examples! Let me know what you guys think, and how I could make it useful for you guys! submitted by /u/princealiiiii |
| |
The July issue of Computer Vision News includes RSIP Vision‘s choices for BEST OF CVPR 2019. Read 48 pages with exclusive articles on AI, computer vision and deep learning. Exclusive interview with Andrew Fitzgibbon on page 20. Subscribe for free on page 48! Enjoy! submitted by /u/Gletta |
Hey, so GF is getting into deep learning and is going to build a PC so she can build, train, and run nets at home. Right now I’m having a hard time helping her decide between an AMD Ryzen 5 3600 and an Intel Core i5 9600k.
I have the option to get a 9600k for $180 even. The 3600 will cost $200 + tax.
Both will be paired with a 2060 Super or 2070 Super + 16 GB DDR4 3600 CL17.
I don’t have as much DL experience I’m not well informed enough to make this decision alone. I know the CPU will mainly be used for preprocessing tasks. I read somewhere that numpy operations are faster on intel processors. Suggestions?
submitted by /u/omarkhwj
[link] [comments]