publishOn vs subscribeOn in Project Reactor 3

It took me sometime to understand it, maybe because publishOn is usually explained before subscribeOn, here’s a hopefully more simple layman explanation. subscribeOn means running the initial source emission e.g subscribe(), onSubscribe() and request() on a specified scheduler worker (other thread), and also the same for any subsequent operations like for example onNext/onError/onComplete, map etc … Read more

use mat-datepicker directly without input

turns out this is pretty straightforward import the MatDatePickerModule as per usual and then simply use the mat-calendar selector <mat-calendar></mat-calendar> In order to hook into the selection via typescript @ViewChild(MatCalendar) _datePicker: MatCalendar<Date> ngOnInit() { this._datePicker.selectedChange.subscribe(x => { console.log(x); }); }

Cannot push on Github suddenly

The latest issue I had : remote: error: GH006: Protected branch update failed for refs/heads/master. remote: error: Cannot force-push to this protected branch To ! [remote rejected] master -> master (protected branch hook declined) error: failed to push some refs to ‘ Because I’m admin/owner I was able to go and do the following … Read more

Meaning of parameters in torch.nn.conv2d

Here is what you may find torch.nn.Conv2d(in_channels, out_channels, kernel_size, stride=1, padding=0, dilation=1, groups=1, bias=True, padding_mode=”zeros”) Parameters in_channels (int) – Number of channels in the input image out_channels (int) – Number of channels produced by the convolution kernel_size (int or tuple) – Size of the convolving kernel stride (int or tuple, optional) – Stride of the … Read more