#Unity3D – Making a CustomVision.ai HTTP Post call to have a better #MRTK experience with #CognitiveServices @ivanatilca

Buy Me A Coffee

Hi !

Quick post today, with mostly sample code. And, it’s all about a scenario that we faced with Ivana a couple of days ago while we were using MRTK and we were trying to use some Cognitive Services.

As of today, not all the services in Cognitive Services are supported and have official Unity3D support. At the end, it’s not a problem, we can just make an HTTP Post call, and that’s it. However, this is not as easy as is supposed to be.

So, after facing some issues with the System.Net.HttpClient library, I decided to use UnityWebRequest. This library main objective is to work with HTTP Forms, however we can manage to send an image with a sample like this:

As we can see in the previous post, there is no async / await support here. So I added a couple of ugly lines of code to support this. We can improve this to have a timeout or delay applied here. As for this sample, this works great.

As a bonus, you can watch the full presentation in the Global XR YouTube channel here

Happy coding!

Greetings

El Bruno

References

Crear aplicaciones en tiempo real con Blazor y SignalR

Mteheran's Blog

Blazor es uno de los frameworks para Web Assembly mas avanzados del momento y por otra parte SignalR es una librería ligera y fácil de implementar, que nos permite incorporar comunicación en tiempo real dentro de nuestras apps, en este post aprenderemos como combinar estas 2 tecnologías.

Como es usual lo primero que debemos hacer es instalar la librería de SignalR y configurar nuestro hub:

Podemos hacerlo desde el gestor de NuGets con Visual Studio o podemos utilizar el comando en la consola:

Install-Package Microsoft.AspNetCore.SignalR -Version 1.1.0

Debemos configurar SignalR de una manera general en el proyecto agregando el middleware y utilizando services.AddSignalR(); y endpoints.MapHub(“/chat”); en Startup.cs

    public void ConfigureServices(IServiceCollection services)
    {
        services.AddControllers();
        services.AddSignalR();

        services.AddResponseCompression(opts =>
        {
            opts.MimeTypes = ResponseCompressionDefaults.MimeTypes.Concat(
                new[] { "application/octet-stream" });
        });

        services.AddCors(options => options.AddPolicy("CorsPolicy", builder =>
        {
            builder
                .AllowAnyMethod()
                .AllowAnyHeader()
                .AllowAnyOrigin();
        }));
    }

 public void Configure(IApplicationBuilder app, IWebHostEnvironment env) { if (env.IsDevelopment()) {…

View original post 477 more words

#Hololens2 – Project sizes using #MRTK

Buy Me A Coffee

Hi !

Quick post today. When I started with Hololens 1, Unity and the Hololens Toolkit a couple of years ago, I did this exercise to have a sense of the required disk space for my projects and tests.

I realize that I didn’t blogged this, so here is an updated version using the latest versions. Here are the tools and versions I’m using:

  • MRTK 2.4
  • Unity 2019.4.6f1
  • Visual Studio 2019 Preview (16.7.0)

And using this tools I follow the steps defined in “Initializing your project and deploying your first application” (see references). Let’s take a look at the disk usage.

  • Create an empty 3D project with Unity.
    Disk Size: 49 MB
  • 2. Build the project in Unity.
    Disk Size: 200 MB
  • Import the MRTK 2.4.0 Foundation package in Unity.
    Disk Size: 332 MB
  • Build the project in Unity.
    Disk Size: 668 MB
  • Build the output in Visual Studio 2019 for the HL2.
    Disk Size: 3 GB
  • Apply MRTK Configuration and Settings for a HL2 in Unity and Build.
    Disk Size: 3.10 GB
  • Build the output in Visual Studio 2019 for the HL2.
    Disk Size: 3.68 GB

So, as you can see, a ready-to-go final project will require around 3.5 GBs disk space. Get ready your credit card for a new SSD !

Happy coding!

Greetings

El Bruno

Resources

#Podcast – NTN 60 – Experiencias creando negocios de Datos e Inteligencia Artificial a nivel mundial y mucho más. Bonus: Historias de cuando Atari hacía más que juegos

Buy Me A Coffee
NTN 60 - Experiencias creando negocios de Datos e Inteligencia Artificial a nivel mundial y mucho más. Bonus: Historias de cuando Atari hacía más que juegos

Buenas!

Hoy tenemos la suerte de hablar con Fernando Guerrero y Juan Quijano sobre sus experiencias como CEO. La pregunta “Qué hace un CEO_” es parte del podcast, sin embargo, lo más interesante es ver como estas iniciativas crecieron a nivel mundial, como el talento y el trabajo fueron pilares importantes de su éxito.
En el camino también aprendí que Atari, si Atari, no solo hacía consolas de videojuegos; esto y mucho más!

Speakers

  • Fernando G. Guerrero es el CEO de SolidQ Global SA y de Nouss Intelligence SL (LinkedIn).
  • Juan Quijano es Microsoft Certified Trainer, Arquitecto de Soluciones en Azure, Consultor independiente en implantación de DevOps (LinkedIn)
  • Bruno Capuano es Canada Innovation Lead at Avanade and Microsoft AI MVP (LinkedIn)

Ir a descargar

Happy coding!

Greetings

El Bruno

#docker – Updating docker containers automatically with Watchtower. Bonus: let’s learn Go !

Buy Me A Coffee

Hi !

A couple of days ago, I wrote about how I like Portainer as a visual interface to manage docker (see references). In one of the comments, Marco suggested also an option to automatically update all my containers.

As I explained in my post, the basic steps for this are

  • docker stop
  • docker rm
  • docker pull
  • docker run

Super easy, but tedious if you need to do this several times. Let’s meet Watchover.

Watchtover has the ability to “watch” running Docker containers on either the same local or remote host, check if there is a newer image in the remote registry, and then update the container with the new image using the same configuration options it was instantiated with.

I give this a try, and I found that it was very easy, just a command

docker run -d \
    --name watchtower \
    -v /var/run/docker.sock:/var/run/docker.sock \
    containrrr/watchtower

And, there is a personal bonus here. I’ve been looking for an excuse to start to play around with Go, and this is the one. I think, I’ll use the excuse of update my containers as my next phase on Go learning.

Happy coding!

Greetings

El Bruno

References

Personalizando nuestro [GitHub]

Vicente G. Guzmán Lucio

GitHub API OAuth in 2020. - DEVSabemos que GitHub hace parte de nuestro día a día y porque, además de funcionar como un repositorio en el que podemos encontrar algo nuevo para nuestros desarrollos, es un lugar donde siempre encontraremos a alguien dispuesto a ayudarnos a solucionar un bug o un problema en nuestro código. El año pasado gracias a GitHub se solucionaron alrededor de unos 20 millones de errores y fallos.

Y así como todas las tecnologías mejoran constantemente, Github no se queda atrás y en su última actualización ha traído una nueva funcionalidad muy interesante, la cual nos permitirá personalizar de manera más profunda nuestro perfil.

Esto mediante del famoso archivo README.md, el cual como ya sabemos incluye información general del proyecto y/o más específica como:

  • Por qué el proyecto es útil.
  • Quien mantiene y contribuye con el proyecto.
  • Cómo los usuarios pueden comenzar con el proyecto.

Así mismo y como muchos lo hacemos…

View original post 244 more words

#docker – How to update Portainer (big fan here!)

Buy Me A Coffee

Hi !

I’m a big fan of Portanier. I usually will go for a graphical interface on top of a command line option, and to manage my docker labs, Portainer is my best choice for this.

Portainer is a lightweight management UI which allows you to easily manage your different Docker environments (Docker hosts or Swarm clusters). Portainer is meant to be as simple to deploy as it is to use. It consists of a single container that can run on any Docker engine (can be deployed as Linux container or a Windows native container, supports other platforms too). Portainer allows you to manage all your Docker resources (containers, images, volumes, networks and more) ! It is compatible with the standalone Docker engine and with Docker Swarm mode.

Portainer (see references)

From time to time, we have updates for Portainer and I always make a mess doing this manually. So here is my personal cheat sheet for the next one

  • stop Portainer container
  • remove Portainer container
  • get latest Portainer image
  • run Portainer

And the docker commands are

docker stop Portainer
docker rm Portainer
docker pull portainer/portainer
docker run -d -p 8000:8000 -p 9000:9000 --name="Portainer" -v /var/run/docker.sock:/var/run/docker.sock -v portainer_data:/data portainer/portainer

Portainer is updated and now I got just news in the home page !

portainer home page

Happy coding!

Greetings

El Bruno

Resources

#Office365 – HowTo access to the new Lists features

Buy Me A Coffee

Hi !

If you are looking forward to test the new Microsoft Lists (see references), and you are in First Release of office Microsoft 365, there is an easy way to access to Lists. In 2 clicks, you may have access to this:

office 365 in lists view

You need to select OneDrive, from the Office 365 menu, and change the [onedrive] part of the url for [lists].

office 365 in onedrive view

Super easy !

Happy coding!

Greetings

El Bruno

Resources

#Azure – Easy fix to subscription is not registered to use microsoft.insights

Buy Me A Coffee

Hi!

Azure days for me and weird behavior when I was trying to enable some monitoring resources in an IoT Hub resource. In random times, I get an error similar to this one

The subscription ‘[subscription id]’ is not registered to use microsoft.insights.

And, it was weird because when I check the Resources providers available and registered for my subscription, the [microsoft.insights] appeared as [registered].

azure notifications displaying the monitoring microsoft insights issue

So, I tested a couple of reset scenarios, some other PowerShell scripts, and at the end the solution was the easiest one:

Unregister and Register again the provider.

5 minutes later, my monitoring capabilities were back available for me.

azure subscription resource provider

Again, it happened at random times, so there maybe an external factor also in this scenario.

Happy coding!

Greetings

El Bruno

Crear un reproductor de música en un skill de Alexa con Alexa .NET

Mteheran's Blog

Alexa .NET es la librería para C# que te permite crear skills para Alexa de una manera super fácil. Si aun no sabes como comenzar te recomiendo seguir la siguiente guía:

https://techcommunity.microsoft.com/t5/windows-dev-appconsult/build-your-first-alexa-skill-with-alexa-net-and-azure-functions/ba-p/317930

Si ya sabes como construir tu skill acá te explico como agregar un reproductor de música a tu skill, lo primero es asegurarte que el audio player este habilitado en tu skill. Dentro de las interfaces debemos revisar que si este habilitado:

Luego en nuestro código debemos verificar en intent de nuestro skill y también el intent de amazon.resumeintent ya que si el usuario detiene o pausa y luego continua queremos seguir reproduciendo la canción. En el ejemplo mi intent se llama music.

                    case "music":
                    case "amazon.resumeintent":

Luego vamos a necesitar la URL del MP3 que deseamos reproducir, debemos asignarle un tocken, en este caso estoy utilizando el himno nacional de Colombia

string audioUrl = "https://web.archive.org/web/20041019060651if_/http://www.navyband.navy.mil/anthems/ANTHEMS/Colombia.mp3"; string audioToken…

View original post 104 more words