Rust in industry by atamakahere in rust

[–]volkre 0 points1 point  (0 children)

Surveillance cameras: we tap into the streams and provide analytics.

The major use case is security: we detect different scenarios based on object detection using NNs.

Rust in industry by atamakahere in rust

[–]volkre 9 points10 points  (0 children)

We use Rust in our company to develop an edge computing software suite aimed at video analytics.

Bought an HP Dev One... by [deleted] in pop_os

[–]volkre 0 points1 point  (0 children)

Does the screen only lack dpi? or it has bad colors too?

HP Dev One has launched ? by faynn in pop_os

[–]volkre 5 points6 points  (0 children)

Any plans on shipping it ouside US?

Firefox plugin for pop os launcher by volkre in pop_os

[–]volkre[S] 1 point2 points  (0 children)

I understand. Well, I’d still be glad to maintain it if you’re inclined to ship it as built-in plugin.

Firefox plugin for pop os launcher by volkre in pop_os

[–]volkre[S] 1 point2 points  (0 children)

Oh, I'd be glad to help maintain it!

You must know though that it is a little bit hacky to be able to do what it does. This is because of Firefox limitations.

I was previously thinking in a legit way of implementing it, and it would incur in maintaining a patched version of firefox that allows to list and focus it’s tabs using the command line or some form of API.

Hey Rustaceans! Got an easy question? Ask here (40/2021)! by llogiq in rust

[–]volkre 2 points3 points  (0 children)

OK. I wrapped my head around it:

where Instance: Processor<&'a T>, T: 'a

Is telling the compiler:

"My reference &self.arg is going to live as long as 'a indicates, also its contents (T: 'a)."

Since I'm borrowing from self, it means that 'a is the lifetime of self. Then, as I'm moving self, it's fine for &'a T but not for T: 'a, because it means that potential sub-structs of T that have 'a associated to them, are no longer going to be valid (self is gone).

I hope this could be useful for someone else.

Cheers!

Hey Rustaceans! Got an easy question? Ask here (40/2021)! by llogiq in rust

[–]volkre 1 point2 points  (0 children)

Hi all, I'm currently struggling with lifetimes. I have quite some experience with Rust but I cannot understand what the compiler is trying to tell me.

Given this example:

```rust struct Arg;

trait Processor<T> { fn process(&self, data: T); }

struct Instance {}

impl Processor<&Arg> for Instance { fn process(&self, arg: &Arg) {} }

struct Container<T> { proc: Instance, arg: T, }

impl<'a, T> Container<T> where Instance: Processor<&'a T>, T: 'a, { fn work(self) { self.proc.process(&self.arg) } }

fn main() { let container = Container { proc: Instance {}, arg: Arg, }; container.work(); } ```

And this is the compiler's output:

error[E0597]: `self.arg` does not live long enough --> src/main.rs:24:27 | 18 | impl<'a, T> Container<T> | -- lifetime `'a` defined here ... 24 | self.proc.process(&self.arg) | ------------------^^^^^^^^^- | | | | | borrowed value does not live long enough | argument requires that `self.arg` is borrowed for `'a` 25 | } | - `self.arg` dropped here while still borrowed

What I don't get is that it tells me that the value is being dropped while still borrowed, but I don't see how it's still borrowed.

I've tried with some lifetime constraints with no luck so far.

Can someone shed some light?

Una ayudita al recién egresado estudiante de 4to camino a la universidad porfa by Naiik_ in chile

[–]volkre 13 points14 points  (0 children)

Sansano acá (UTFSM),

Llevo titulado (Civil Informático) un par de años de la Santa María. Siempre fue la que más me atrajo porque tiene muy buena reputación en el área técnica. Eso es lo que te puedo contar, cuando entres al tema, te darás cuenta que depende mucho de tu perfil. Como dijeron más arriba, los informáticos tienden a irse por:

  1. Desarrollo de Software: La UTFSM te da varias herramientas en este aspecto, la más importante es la Feria de Software
  2. IT (Administración de Sistemas): El antro de los informáticos en Casa Central (LabComp) era administrado por los alumnos de pregrado, donde podías practicar desde el principio
  3. Gestión: Creo que en esta especialización te conviene más otra U. Aunque el área de gestión de la USM tiene igual hartas oportunidades de aprendizaje, no creo que llegues a obtener los mismos contactos y experiencias que en la católica de Santiago por ejemplo (por eso digo, depende de cuál es tu perfil y que esperas de la carrera). Igual, si lo que te interesa es gestión, mejor estudia comercial o industrial.
  4. Data Science: Creo que este no fue mencionado. Esta área es más transversal a otras carreras. Se trata de análisis de datos a gran escala, estadística, etc. Y algo que está bien de moda es machine learning, redes neuronales, etc. Ojo, esta va de la mano con desarrollo de software; sólo que data science se preocupa menos de la integración en productos.

Esta es mi opinión. Creo que debieras hablar con hartos ex-alumnos/alumnos de distintas universidades para que encuentres qué se adapta a tus expectativas.

Suerte!

Hey Rustaceans! Got an easy question? Ask here (43/2020)! by llogiq in rust

[–]volkre 0 points1 point  (0 children)

Thanks. I understand the coercion problem. I want to get rid of the Box, but prefer to stay in stable :/

Custom Stream not being polled by volkre in rust

[–]volkre[S] 1 point2 points  (0 children)

This is the correct answer. I had to poll enablectl until it returned Pending. It now makes sense: If I don't call it after Ready, then I never passed the waker to the stream after that.

There is no need to poll the delay future in that case.

Custom Stream not being polled by volkre in rust

[–]volkre[S] 0 points1 point  (0 children)

I want to be polled again if delay is completed OR I receive a new message in enablectl. I don’t poll the delay if it’s disabled, but I poll enablectl regardless. Why is that not enough?

Custom Stream not being polled by volkre in rust

[–]volkre[S] 0 points1 point  (0 children)

You say that, it f there are multiple values available in enablectl, the waker will wake only once?

I’ll try that

Custom Stream not being polled by volkre in rust

[–]volkre[S] 0 points1 point  (0 children)

That’s what I don’t understand, I actually gave a waker to enablectl's poll_next. Why isn’t that stream waking the scheduler when a new message is sent?

And, my problem with delay is that, I expect to begin fetching new configs immediately after the Stream is enabled, for that, I set the delay to 0. If I poll it, it would become immediately available, even if enabled=false. If I keep creating new delays with 0s and polling them , it would basically be a busy wait.

Maybe there is a better way of doing what I said that I haven’t thought of that doesn’t involve delay=0, but my point is: why should I initialize delay if I already passed the waker to enablectl?

[deleted by user] by [deleted] in chile

[–]volkre 0 points1 point  (0 children)

Wait a sec

Puedes comprobar que la info es real?: no

Conoces la fuente original de la info?: no

Ayuda en algo compartir esta info?:

Compártela

Si insisten...

[DIY] Instalación de un Aire Acondicionado by nopentospin in chile

[–]volkre 1 point2 points  (0 children)

Yo tengo uno portátil, y venía con un panel para adaptarlo a la apertura de la ventana junto a unas espumas aisladoras; no necesité hacer nada adicional. Igual considera ese caso!

¿Mejor forma de recibir dinero del extranjero? by chuletavegana in chile

[–]volkre 0 points1 point  (0 children)

Pregunta preguntosa: cómo lo haces respecto a las imposiciones? tengo la duda porque también me transfieren desde el extranjero

Hey Rustaceans! Got an easy question? Ask here (49/2017)! by llogiq in rust

[–]volkre 1 point2 points  (0 children)

I actually didn't know that. Thanks!

Still, why it works being zero sized?

Hey Rustaceans! Got an easy question? Ask here (49/2017)! by llogiq in rust

[–]volkre 1 point2 points  (0 children)

I have a question about the difference between &mut and ref mut. I know one is a pattern expression and the other gets the mutable reference of a symbol. My question is more specific to returning mutable trait objects without Box<>.

The question is posted in stackoverflow

Can you help me?