Invalid opcodes in rectavoider.svc16

Hello, cool repo you've got here :)
I have created a simple disassembler that just reads bytes from the svc16 file as an Vec<u8> buffer and then converts them to an Vec<u16> containing the instructions while using from_le_bytes.
I then iterate through the u16 vec taking 4 values at a time. Then map through them and I have an array [String; 0x10] called op_codes that basically has the opcodes listed in the readme file in order. The disassembler then matches the 1st out of the 4 values to the op_codes and replaces them with the string version of the opcode (for example 0 gets replaced with "Set").
The disassembler works fine with all_colors.svc16 but throws invalid opcode when disassembling rectavoider.svc16. Upon further inspection, I found out that the file has invalid opcodes, the first occurence of which occurs at line 4711 after executing
hexyl rectavoider.svc16 -pv --panels 1 > hex.txt

The result is:

The opcode observed is c8 00 in hex which translates to 200 in decimal. From my understanding, there is no opcode beyond 16(?).
On further inspection, dozens of such invalid opcodes were observed.
Is there anything I'm missing out on or doing wrong?
I obviously have executed rectavoider.svc16 with svc16 and the game works as expected.
Any help is much appreciated and thanks for creating this amazing repo!

Hello,
first of all cool work!
What is happening here is that the game does not just contain instructions.
It also contains the data for the sprites. This is fine, as long as I never try to run them as code.
I stored the picture of the galaxy in the background by using the individual bits of the values so I get 16 pixels per value. This is why the values are bigger than 15. There are also some other ""literal values" already written in.
I could not reproduce which one you would first encounter at 4711 (,but the range sounds about right).
(One thing that I  should add is that the demo-game is 1. in no way compiled in an efficient or even sensible way and 2. I think it might contain unused code. )

first of all cool work!

Thank you so much Jan! Do you mind if I publish it to github once it's in a usable state? However I think people should build that themselves but doesn't hurt to put it out there(?).

What is happening here is that the game does not just contain instructions.
It also contains the data for the sprites. This is fine, as long as I never try to run them as code.
I stored the picture of the galaxy in the background by using the individual bits of the values so I get 16 pixels per value. This is why the values are bigger than 15. There are also some other ""literal values" already written in.

Ah cool, I expected this! So in order to improve my disassembler, I basically have to track what code never runs? If I do manage to track it down like that, how do I store these values such that when it's assembled back, it runs fine? That would need the use of something like section.data in x64 asm or in simpler terms, variables?
What I am thinking about is, there's no official assembly for svc16 right. Like there could be a very close one that looks like assembly and has basic stuff like variables and stuff baked in?

(One thing that I  should add is that the demo-game is 1. in no way compiled in an efficient or even sensible way and 2. I think it might contain unused code. )

Oh yea I completely am aware of that, thanks! I am quite interested in how you got the text rendering working. Is it something like you store bitmaps or images of numbers and text and then just display them or have you got a rasterizer 👀?
Also, are you supposed to make a compiler for an existing lang like C or make an entirely new lang because of the marginal differences?
I was trying to disassemble this to get an idea of how the text rendering is done (like the score, "game over", etc) 😅

Do you mind if I publish it to github once it's in a usable state? However I think people should build that themselves but doesn't hurt to put it out there(?).

Yes, please put it out there! I think that having an inspector for a rom would be completely universal.
I think that this could also be in this repo either as a separate program or a subcommand of the emulator. But that is up to you.

Ah cool, I expected this! So in order to improve my disassembler, I basically have to track what code never runs? If I do manage to track it down like that, how do I store these values such that when it's assembled back, it runs fine? That would need the use of something like section.data in x64 asm or in simpler terms, variables?

I think, unfortunately, there is no way to determine if something is supposed to be read as instructions or data from just looking at the rom. The program could compute an arbitrary address at runtime and then set the instruction pointer to that value. This also means that the address of the opcodes does not have to be divisible by four!
I am sure there is a good way to present it in a helpful way anyway.

What I am thinking about is, there's no official assembly for svc16 right. Like there could be a very close one that looks like assembly and has basic stuff like variables and stuff baked in?

I have made something like this for the test programs. I can explain it if you are interested but I am not married to it. It is just a convention after all. I am pretty open to the idea of making a good assembler available. I just said that I am not providing one in the Readme to make it clear that the specification is completely neutral. We could make a different directory in this repo for the assembler and make it clear that it is only one possible implementation? (Or a different repo for developing tooling.)

Oh yea I completely am aware of that, thanks! I am quite interested in how you got the text rendering working. Is it something like you store bitmaps or images of numbers and text and then just display them or have you got a rasterizer 👀?

No, it is really just bitmaps of characters. Hopefully at some time in the future there could be a working rasterizer.
(The "Game Over" is just one sprite.)

Also, are you supposed to make a compiler for an existing lang like C or make an entirely new lang because of the marginal differences?

Whatever seems more interesting to you.

I created a repo (We can figure that organisation thing later).

Great move, thanks for the invite!

To be honest, I am not open to changing the architecture. It is supposed to be a bit weird. The idea is that the programmer has this block of memory and they have to figure out what to do with it. Where should the functions go? Where should the data go? Does the data need to be compressed to fit into the available memory? This is all up to them to figure out.

Ah okay, I get it now. I had a vague view point of the goals this project had but now I have a clear view of the goals. It should be simple but you're supposed to do the critical thinking involved yourself so there's no "magic" happening.

My "assembly" looks a bit like this:
# main
set _color 200
cmp "0" _mouse_key 502
skip 2 0 502
	set _color 5000
cmp "1" _mouse_key 502
skip 2 0 502
	set _color 50000
set _counter 0
	cmp "65534" _counter _loop_done
	print _color _counter
	add "1" _counter _counter
skip 0 3 _loop_done

print "65534" _mouse_pos
set _x_mask 255
band _x_mask _mouse_pos _mouse_x
sub _mouse_pos _mouse_x _mouse_y
div _mouse_y "256" _mouse_y
set _counter 0
	mul _mouse_y "256" _current_cross
	add _current_cross _counter _current_cross
	print "65534" _current_cross
	add _counter "1" _counter
	cmp _x_mask _counter _loop_done
skip 0 5 _loop_done

set _counter 0
	mul _counter "256" _current_cross
	add _current_cross _mouse_x _current_cross
	print "65534" _current_cross
	add _counter "1" _counter
	cmp _x_mask _counter _loop_done
skip 0 5 _loop_done

sync _mouse_pos _mouse_key
goto 0

(This is a program I used to test mouse input). Then the program does a couple of things to run this:

replace the opcodes with numbers
find the "literal numbers" and put their value somewhere into the rom. They are then replaced with that address.
The position of the #blocks is also available as literals, that makes it possible to call functions, because they can be written as separate blocks.

That is the basic idea.

Amazing to see the code! This however makes disassembly very hard since there's no specific rule to how the programs assembling the "assembly" work. So the assembler that allocates memory based on how the assembler wants to allocate memory. So one program compiled by one assembler may not be disassemblable by a "general" disassembler? In that case we should first make a specification for an assembly type intermediate language and then point out to examples as "this code was assembled using svct's assembler and can be disassembled using svct's specific disassemblers only". That should make sense as real computers have a very strict assembly syntax and obviously if you create an assembler than works differently, you may not be able to disassemble it.
For example x86 disassemblers can't disassemble x64 machine code because standards of both are different and the underlying machine code would be different.
Implementing a rom analyzer should be feasible but I think it should come after the assembler and disassembler?

Storing the fonts in the ROM is exactly what one would have to do. All information to emulate the program must be contained in the ROM itself. So it runs the same everywhere. The last sentence I want to say is "It works on my virtual machine". So filesystem access is definitely out of the question. I think that font rasterization might actually be possible.

I get it. What I meant by font rasterization being not possible is, you'd have a very limited set of characters with a 131kb file limit. Some fonts are well above the limit and obviously they could be compressed but then you don't have space for other stuff you'd like to store. However as you've stated, this should be all up to the programmer and I undeniably agree. It should be actually possible to make a small rasterizer.

you don't get floating point operations or signed operations natively but you could fake it in some ways.
I believe that you could at least have a language that looks a lot like C at some point, but I have not built anything that complex yet.

Yea I get the faking "flop"s stuff. It will look like C but it can't be exactly C I think as it's pretty much limited. The architecture doesn't have SIMD and other native stuff for obvious reasons. I propose we make it close to C but not exactly C.

Amazing to see the code! This however makes disassembly very hard since there's no specific rule to how the programs assembling the "assembly" work. So the assembler that allocates memory based on how the assembler wants to allocate memory. So one program compiled by one assembler may not be disassemblable by a "general" disassembler? In that case we should first make a specification for an assembly type intermediate language and then point out to examples as "this code was assembled using svct's assembler and can be disassembled using svct's specific disassemblers only".

Yes, this sounds perfectly reasonable.

Implementing a rom analyzer should be feasible but I think it should come after the assembler and disassembler?

Yes, I do not really know what a general rom-analyzer would really do that you could not do with hexdump.

I get it. What I meant by font rasterization being not possible is, you'd have a very limited set of characters with a 131kb file limit. Some fonts are well above the limit and obviously they could be compressed but then you don't have space for other stuff you'd like to store. However as you've stated, this should be all up to the programmer and I undeniably agree. It should be actually possible to make a small rasterizer.

Without having any knowledge to base my opinion on, I would guess that this would not be a problem of memory. The problem is that with the 3000000 instruction limit, you only get about 45 instructions per pixel. This might not be enough for complicated rasterization. It is, however, enough to index a bitmap. So the much easier way is to include bitmaps for characters.

Yea I get the faking "flop"s stuff. It will look like C but it can't be exactly C I think as it's pretty much limited. The architecture doesn't have SIMD and other native stuff for obvious reasons. I propose we make it close to C but not exactly C.

I think this is a good idea if we want to have a good example project. It would show how you can implement something very normal.
One question I have here, however, is the order of operations. I think it is very important to lock in a final version of the specification for the system itself very early. I guess that no one (including you) would want to invest many hours into building something for a system that could still change. I think that there is nothing standing in the way of this except for finishing the pdf document.

Yes, this sounds perfectly reasonable.

Cool, we will stick to this then.

Yes, I do not really know what a general rom-analyzer would really do that you could not do with hexdump.

I'm not sure either. I don't know what rom analyzers do.

Without having any knowledge to base my opinion on, I would guess that this would not be a problem of memory. The problem is that with the 3000000 instruction limit, you only get about 45 instructions per pixel. This might not be enough for complicated rasterization. It is, however, enough to index a bitmap. So the much easier way is to include bitmaps for characters.

I have created couple of renderers over the past year and I can say that 45 instructions per pixels might be enough. I don't think text falls into complex rasterization, and that is why it shouldn't matter. Why I say it would be a problem of memory is the involvement of complex stuff like graphemes and glyphs. There would be many things to store in memory and I am afraid we might hit OOM. But this is only theory and theory can only take us so far haha. We should worry about this after having the compiler to maintain order of priorities.

I think this is a good idea if we want to have a good example project. It would show how you can implement something very normal.

I absolutely agree, a good example project is definitely needed to help people figure out what they can build.

One question I have here, however, is the order of operations. I think it is very important to lock in a final version of the specification for the system itself very early.

Fantastic thought. I agree that the specification should be deemed complete and no major changes being introduced after being declared stable.

I guess that no one (including you) would want to invest many hours into building something for a system that could still change. I think that there is nothing standing in the way of this except for finishing the pdf document.

Well, as for me, I think I can adapt but a systematc approach would be to complete the specfication first.
Thanks for all the good stuff!

Great!
I opened an issue about the question of adding sound, which would be my last blocker. If this is solved, the specifications are only a matter of expanding the writing I already copied from the readme. If you want to help, you have probably found the .typ document. (If you have not heard of it, it can be compiled with typst).
Then thank you very much for collaborating on this and see you in another thread!

I opened an issue about the question of adding sound, which would be my last blocker. If this is solved, the specifications are only a matter of expanding the writing I already copied from the readme. If you want to help, you have probably found the .typ document. (If you have not heard of it, it can be compiled with typst).
@JanNeuendorf would love to help but I'm not sure how I should write the specification. What more is there to be added? Yes, I have found the .typ document and have taken a look at it and I've used typst before so nothing to worry about.


Fake async

@AleksBekker if you get a chance to look at any of the comments that would be sick. If not we'll deal with it on Tuesday

@WyattRoss I'll try, but I might be busy moving this weekend

Hey @TrevorBrunette @WyattRoss, could y'all please be more specific in comments in PRs, especially ones you would like me to review. I'm not quite on the exact same page with y'all, especially on things like code conventions, and since we don't have any documentation on these things, I need y'all to be very exact with what the problems are and why. Otherwise, I simply cannot work on issues

Hey @TrevorBrunette @WyattRoss, could y'all please be more specific in comments in PRs, especially ones you would like me to review. I'm not quite on the exact same page with y'all, especially on things like code conventions, and since we don't have any documentation on these things, I need y'all to be very exact with what the problems are and why. Otherwise, I simply cannot work on issues

@AleksBekker I'll try to be better about comments. I was only thinking about wyatt reading them when I was writing them, so I was fairly sparse. This PR in particular is massive, so I understand the need to be more precise.

Many features added / changed in this PR are untested -- we should write tests for the reader and the new transformation functions.


Unable to instantiate LSTM and GRU layers.

Describe the issue:
Using version 2.6 of NNI is impossible to instantiate LSTM and GRU layers. However, this does not happen in version 2.5. This can be reproduced with the following Code
This can be reproduced in Google Colab. Remember to restart the runtime between each pip installation of NNI.
Environment:

NNI version: 2.6 and 2.5
Training service (local|remote|pai|aml|etc): remote
Client OS:
Server OS (for remote mode only): Ubuntu 18.04.5 LTS
Python version: 3.7.12
PyTorch/TensorFlow version: 1.10.0+cu111
Is conda/virtualenv/venv used?: no
Is running in Docker?: no

Configuration:

Experiment config (remember to remove secrets!): no experiment config is needed.
Search space: no search space is needed.

Log message:

nnimanager.log:
dispatcher.log:
nnictl stdout and stderr:

No experiments have been performed
How to reproduce it?:

Install version 2.6 of NNI
Import the library using "import nni.retiarii.nn.pytorch as nn"
Create an LSTM or GRU layer using "nn.LSTM()"

Please try nn.LSTM(input_size=2, hidden_size=2) for now.
We will figure out a fix for this.


docs(validation): follow rename: check_archive → check_archived_root

Thanks for the PR! The book is always hard to keep up-to-date. I appreciate the help!


cant import jpg

When trying to import the following photo

this is happening

I tried to dig to the issue but failed.

The metadata in the file is corrupt. Either your camera or the transfer to your computer broke it. You could look for a tool to fix/remove the metadata from the file and retry the import. F-spot does not have the means to fix this right now.

This file once was successfully imported by the last f-spot that came with
Ubuntu so it would be a regression. I also think F-Spot should be robust,
this is why I decided to share this image. Unfortunately I wasnt able to
fix the code myself.
I know that I can easily fix the exif tags and then the problem is
resolved. However, I just hope that I can contribute to a more robust
f-spot version by sharing this image.
2016-04-20 20:30 GMT+02:00 dkoeb<EMAIL_ADDRESS>
The metadata in the file is corrupt. Either your camera or the transfer to
your computer broke it. You could look for a tool to fix/remove the
metadata from the file and retry the import. F-spot does not have the means
to fix this right now.
—
You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub
https://github.com/mono/f-spot/issues/69#issuecomment-212547283

That's interesting. If the picture was successfully imported in an earlier version of f-spot I assume that taglib-sharp is to blame. This library was updated a few months ago and is used in f-spot for metadata parsing.
I agree that it would be nice if f-spot would still import such images in a sane way. Nevertheless I already consider f-spot robust in this regard as it did not crash but report the image as corrupt.
Thanks for reporting and sharing the image!

Fyi: using the taglib-sharp that comes with f-spot.git I get hundreds of import errors. Thats why I am using  b9f275b7355ac2b71fa2b93b4b1017f5ef0e44ae from their github repo. So I only have one image failing during the import.

I am not sure if the real problem is in taglib library.
If you look at the attached file using exiftool you will see some warnings during parsing of metadata:
$ exiftool -a e9db5d80-029f-11e6-8b9e-2f431bf54715.JPG
After using exiftool to try to fix the errors I was able to import the image:
$ exiftool -exif:all= -tagsfromfile @ -all:all -unsafe e9db5d80-029f-11e6-8b9e-2f431bf54715.JPG
It could be that files were bad from the start and it just happens that new version of library is stricter during parsing and throws and exception.

I agree. Among all the 86 failing jpgs this one fails because of the damaged exif information. Thank you.
In the same matter I wanted to continue with the other missing imports. However, they seem to have good exif information.
Like stated above I once was able to import them with another taglib revision. I tried to reproduce that but failed. I attached one failing example image.

Many if not all images that fail to being imported are from a Sony cam. So I followed this trace.
The error is that I get a System.Overflow exception in the taglib library. This happens directly after taglib/IFD/IFDReader.cs:858 specifically treats the sony header. I dont completely understand what should happen in the code shown below but I recognize that the type parameter is lost in that function. Also a IFDReader is initiated which seem to be unused. So for me it looks like there is no functionality:
if (header.StartsWith (SONY_HEADER)) {
IFDReader reader = new IFDReader (file, is_bigendian, ifd_structure, base_offset, offset + 12, max_offset);
reader.ReadIFD (base_offset, offset + 12, max_offset);
return new MakernoteIFDEntry (tag, ifd_structure, MakernoteType.Sony, SONY_HEADER, 12, true, null);
}
Since I doubt that code I commented it out. It looks like for now I can import all my files:
if (header.StartsWith (SONY_HEADER)) {
// IFDReader reader = new IFDReader (file, is_bigendian, ifd_structure, base_offset, offset + 12, max_offset);
// reader.ReadIFD (base_offset, offset + 12, max_offset);
return new MakernoteIFDEntry (tag, ifd_structure, MakernoteType.Sony, SONY_HEADER, 12, true, null);
}

@codingdave can you create an issue on github.com/mono/taglib-sharp with that information and add me to it? Also, if you can attach an image with the problem that works after commenting out those lines that'd be very helpful.
if you can't add me to the issue, can you put it in the comments here too?

@decriptor on https://github.com/mono/taglib-sharp I cannot find an issues tab and such cannot create that issue.

Also, if you can attach an image with the problem that works after commenting out those lines that'd be very helpful.

Unfortunately I cannot reproduce my hacks from that time. I will go baby steps and when I find the time try to reproduce it and have it well documented.

@codingdave I just enabled issues on taglib-sharp. Not sure why it wasn't enabled already.

@codingdave Do you want to submit a PR to bump taglib-sharp to pull in this fix?

@decriptor  im confused: I did the PR for taglib-sharp and it was merged into taglib-sharp. Since it is a submodule of f-spot i was hoping that the merge will end up in f-spot. Is there something left to do on my side?

submodules point at a specific commit. We need to bump which commit it is looking at. I've done that here -> https://github.com/mono/f-spot/commit/91d6141ab02f40884d7371ce67c050612c7bda53

submodules point at a specific commit. We need to bump which commit it is looking at. I've done that here -> https://github.com/mono/f-spot/commit/91d6141ab02f40884d7371ce67c050612c7bda53

okay, thank you. f-spot works now for my cases.

Very happy to hear that


insider build 19.0.28666.0 - wrong parameter value passed in Approvals Mgmt: OpenApprovalsPurchase

In the Approvals Mgmt codeunit, the following function uses DATABASE::"SalesHeader" but it should be DATABASE::"Purchase Header"
procedure OpenApprovalsPurchase(PurchHeader: Record "Purchase Header")
begin
    RunWorkflowEntriesPage(
        PurchHeader.RecordId(), DATABASE::"Sales Header", PurchHeader."Document Type", PurchHeader."No.");
end;

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. Please do not reply to this, as we do not monitor closed issues. If you have follow-up questions or requests, please create a new issue where you reference this one.


Add com.snowplowanalytics.snowplow.storage/shredding_complete/jsonsch…

…ema/1-0-1 (close #1112)

Cherry-picked into https://github.com/snowplow/iglu-central/pull/1111


Codegen

Provide a codegen function.
strest --output curl
would result in the equivalent curl commands to perform the actions

module options:
https://www.npmjs.com/package/request-as-curl
https://github.com/JarvusInnovations/node-request-to-curl

#77


Issue building the Lib

Have everything setup, but when building the lib getting
In file included from /Users/jeffo/desktop/dev/weather/pico-ssd1306-master/textRenderer/TextRenderer.cpp:1:
In file included from /Users/jeffo/desktop/dev/weather/pico-ssd1306-master/textRenderer/TextRenderer.h:4:
/Users/jeffo/desktop/dev/weather/pico-ssd1306-master/textRenderer/../ssd1306.h:5:10: fatal error: 'hardware/i2c.h' file not found
#include "hardware/i2c.h"
^~~~~~~~~~~~~~~~
1 error generated.
the pico SDK is setup and the env var is setup correctly.  Have tried a few things with CMakeLists.txt with no luck.  Trying to build the examples for basic text.  Any help / direction would be appreciated.

I got this to work with some small changes in the cmake lists file, thanks

From the last comment I understand that you got it working? Can this issue be closed?

Yes

On Dec 22, 2023, at 1:58 PM, Harbys @.***> wrote:
From the last comment I understand that you got it working? Can this issue be closed?
—
Reply to this email directly, view it on GitHub https://github.com/Harbys/pico-ssd1306/issues/18#issuecomment-1868030131, or unsubscribe https://github.com/notifications/unsubscribe-auth/APPVMIS5QOKF2GX4K2VUACTYKXQ7VAVCNFSM6AAAAABA7W3JJGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNRYGAZTAMJTGE.
You are receiving this because you authored the thread.


Add ability to only impute specific columns

Right now, our PerColumnImputer allows us to change the impute strategy for each specific column in the input features. However, it still imputes the entire dataframe! It just gives us control over what imputation strategy we want to use for particular columns.
If we want to enable null column imputation, this "works" in that it imputes the columns with null columns, and other columns should be left untouched. But if a user specifies that they don't want a column to be imputed, this isn't enough!
We could either create a new component or modify the PerColumnImputer. I suggest adding a new parameter such as impute_other that specifies whether or not the columns not specified with impute strategies should be imputed as well. If impute_other is True, we have our current behavior. If impute_other is False, we only impute the columns whose impute strategies are specified.

@angela97lin adding this to the data check actions followup

Also, moving this to the current sprint because we think it's in progress.  Please correct if this isn't the case.


[AIRFLOW-XXX] Add Société générale to company list

Make sure you have checked all steps below.
Jira

[ ] My PR addresses the following Airflow Jira issues and references them in the PR title. For example, "[AIRFLOW-XXX] My Airflow PR"

https://issues.apache.org/jira/browse/AIRFLOW-XXX
In case you are fixing a typo in the documentation you can prepend your commit with [AIRFLOW-XXX], code changes always need a Jira issue.

Description

[ ] Here are some details about my PR, including screenshots of any UI changes:

Tests

[ ] My PR adds the following unit tests OR does not need testing for this extremely good reason:

Commits

[ ] My commits all reference Jira issues in their subject lines, and I have squashed multiple commits if they address the same issue. In addition, my commits follow the guidelines from "How to write a good git commit message":

Subject is separated from body by a blank line
Subject is limited to 50 characters (not including Jira issue reference)
Subject does not end with a period
Subject uses the imperative mood ("add", not "adding")
Body wraps at 72 characters
Body explains "what" and "why", not "how"

Documentation

[ ] In case of new functionality, my PR adds documentation that describes how to use it.

When adding new operators/hooks/sensors, the autoclass documentation generation needs to be added.
All the public functions and the classes in the PR contain docstrings that explain what it does

Code Quality

[ ] Passes flake8

Codecov Report

Merging #4330 into master will decrease coverage by <.01%.
The diff coverage is n/a.

@@            Coverage Diff             @@
##           master    #4330      +/-   ##
==========================================
- Coverage    78.1%   78.09%   -0.01%
==========================================
  Files         201      201
  Lines       16471    16471
==========================================
- Hits        12864    12863       -1
- Misses       3607     3608       +1

Impacted Files
Coverage Δ

airflow/models.py
92.31% <0%> (-0.05%)
:arrow_down:

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 1023e8c...fa5889d. Read the comment docs.


Deterministic instance address using create2 salt

https://github.com/0age/Spawner/blob/master/contracts/Spawner.sol

Next version of the factory should have option to create using create, create2 implicit nonce, or create2 explicit nonce.
Can also add getter to return the the next address, this could be dangerous because of race condition for create and create2 implicit if relied upon.


Fix #6 by chanign yices api interaction as suggested

Fixed the handling of big unsigned integers in #6  as suggested by @jburnim by replacing mk_num with from_string version. This fixes the bug for me.
I was looking into short-circuiting printing to string by only doing it for values greater than 2 billion, but the actual const_term() seems to be represented by a negative value so it's a bit strange.

I added a version of this fix in https://github.com/jburnim/crest/commit/3e5ececd3793c88f18af47853236af34ffde4569 .
Thanks again, @kren1 !


Add optimizer rule to replace inlist with or chain for small expression list

Which issue does this PR close?

Closes #799
Rationale for this change

Speeding up inlist with one or two expressions by converting to a normal boolean expression.
What changes are included in this PR?

Are there any user-facing changes?

Seems it is not faster (yet). Will do some more research

Cool, this is interesting to me since in our query engine we started from the opposite approach of initially rewriting all IN expressions into comparison and OR and are now introducing specialized kernel for IN. Would be very interested in finding out where the threshold for this optimization is. The benefit is probably bigger for dictionary encoded data and numbers since the string comparison itself will involve some branches.

Possibly also related https://github.com/apache/arrow-datafusion/pull/813 as a different performance approach

I might tune this later at a later moment to be for empty/single items instead for which it really should be an improvement, and do some more profiling.
It could also be worse right now because of a slower kernel (how fast is the or ATM?)

Closing a seemingly stale PR -- please reopen if that was a mistake.


Incorrect decodeUplink and encodeDownlink

I guess https://github.com/chirpstack/chirpstack/issues/39 also applies for migration tool.

Could possibly be improved in following way because in Chirpstack v3 there was error logged in the Events tab when decoder failed to decode data in case the data: null was received (which was quite expected).
In Chirpstack v4 the Events tab seems "frozen" upon receiving such message and no more data is logged in the Events tab after that (while LoRaWAN frames continues to log the up/down packets correctly) and ERROR chirpstack::api::internal: Reading event-log returned error: Cannot serialize NaN as google.protobuf.Value.number_value is being continuously logged in the journal (once per second it seems).
// v3 to v4 compatibility wrapper
function decodeUplink(input) {
    // Check if bytes array is not empty:
    if ( input.bytes.length > 0 ) {
        return {
            data: Decode(input.fPort, input.bytes, input.variables)
        };
    }
    else {
        return {
            data: { data: null }
        };
    }
}

Thanks!
With regards the error:

ERROR chirpstack::api::internal: Reading event-log returned error: Cannot serialize NaN as google.protobuf.Value.number_value

I think that is better fixed in the ChirpStack code itself. I'll look into this.

@mmrein the above commit to ChirpStack fixes this issue properly.


Why does the tiktokenizer demo output completely different token numbers than the actual npm package?

So in the tiktokenizer demo, the textarea box looks like this (I'm using the gpt-3.5-turbo model):
<|im_start|>system
You are a helpful assistant<|im_end|>
<|im_start|>user
Yes, please help<|im_end|>
<|im_start|>assistant

And the token array looks like this:
[100264, 9125, 198, 2675, 527, 264, 11190, 18328, 100265, 198, 100264, 882, 198, 9642, 11, 4587, 1520, 100265, 198, 100264, 78191, 198]

But when I use the exact same text in my javascript file:

I get completely different tokens as you can see in the terminal panel the right side.
And no, it's not because you see triangles in the string in my screenshot, that's just because of the font I'm using.
Can you explain what's going on here?

Hi @Evertt!
The reason why you are seeing different tokens is due to the behaviour of special tokens. By default, no special tokens are being added to the tokeniser.
To get the same token counts, you might want to do something like this:
if (model.startsWith("gpt-4") || model.startsWith("gpt-3.5-turbo")) {
  return encoding_for_model(model, {
    "<|im_start|>": 100264,
    "<|im_end|>": 100265,
    "<|im_sep|>": 100266,
  });
}

Hi @dqbd, I don't know why, but instantiating Tiktoken with an object that maps new special tokens to integers... It actually makes my app crash...
This is the code I use:
import type { ChatCompletionRequestMessage } from<EMAIL_ADDRESS>import tiktoken, { type TiktokenModel } from<EMAIL_ADDRESS>
const messages: ChatCompletionRequestMessage[] = [
  { role: "system", content: "You are a helpful assistant" },
  { role: "user", content: "Hey, can you see my name?", name: "Evert" },
  { role: "assistant", content: "Yes I can, your name is Evert." },
]

// This is just a utility type to extract all the gpt-3.5 and gpt-4 models from the `TiktokenModel` union
type ExtractGPT<T extends string> = T extends `gpt-${infer R}` ? `gpt-${R}` : never
type GPTModel = ExtractGPT<TiktokenModel>

function getChatGPTEncoding(
  messages: ChatCompletionRequestMessage[],
  model: GPTModel
) {
  const isGpt3 = model.startsWith("gpt-3.5")

  const msgSep = isGpt3 ? "\n" : ""
  const roleSep = isGpt3 ? "\n" : "<|im_sep|>"

  return [
    messages
      .map(({ name, role, content = "" }) => {
        return `<|im_start|>${name || role}${roleSep}${content}<|im_end|>`
      })
      .join(msgSep),
    `<|im_start|>assistant${roleSep}`,
  ].join(msgSep)
}

const input = getChatGPTEncoding(messages, "gpt-3.5-turbo")

// See? I added the special tokens just like you recommended
const tik = tiktoken.encoding_for_model("gpt-3.5-turbo", {
  "<|im_start|>": 100264,
  "<|im_end|>": 100265,
  "<|im_sep|>": 100266,
})

const encoded = tik.encode(input)
const decoded = tik.decode(encoded)

const string = new TextDecoder().decode(decoded)
console.log("input:", input)
console.log("encoded:", encoded)
console.log("decoded:", string)
tik.free()

It used to work, as in not crash with an error. I just got different integers than the playground gets. But I assume that the token count would probably still be the same?
But since I've added that object to map extra special characters, when I run the code I get this error:
Uncaught (in promise) Error: The text contains a special token that is not allowed: <|im_start|>

Closing this issue for now, assuming the discussion follows here: https://github.com/dqbd/tiktoken/issues/65


OpenXR bindings

Summary of the PR
Adds OpenXR bindings by reusing the Vulkan generator.
Related issues, Discord discussions, or proposals
#48
Closes #193
Further Comments
This also changes the OpenGL representation of strings to byte* from char* by popular demand.

Thanks!


Turning off proxy

I have exported environment variables (https_proxy, http_proxy), but I don't want to use this proxy with youtube-viewer. If I launch gtk-youtube-viewer from terminal, running 'unset https_proxy http_proxy' before it solves my problem, but I often launch it via dmenu_run. That would be good, if there was an option to not to use proxy.

The env_proxy config-option has been added here. When it's set to 0, it will not use proxy defined in environment variables. By default, it has a value of 1. Changing its value, requires restarting the application.


Comments not colored correctly (or appropiately)

Hey!
Comments inside of .mcfunction files are not highlighted as comments but rather as normal text. Here is an example with the standard VSCode Light Theme. The current behaviour is independent of the theme I use, comments always have the same color as normal text would have.
How is is right now:

As a comparison, here is a Rust file highlighted:

This is actually intended: punctuation and comments are not colorized by DHP. You might want to install Arcensoth's language-mcfunction as well.


cookie consent osano on Prestashop

The message is not shown in the web site even after head file modification and cache clearing.A clear and concise description of what the bug is.
Any suggestion how to make it work?

Without seeing the site that the code is appearing in we can't really offer any suggestions.

I followed this guidance:
https://www.dreamtheme.eu/blog/how-to-add-free-popup-consent-in-prestashop/?unapproved=31&moderation-hash=cdf430749cff4c6067b62e1db5370a9c#comment-31
Then I inserted the code in the head.tpl file as shown below:
{**

2007-2018 PrestaShop

NOTICE OF LICENSE

This source file is subject to the Academic Free License 3.0 (AFL-3.0)
that is bundled with this package in the file LICENSE.txt.
It is also available through the world-wide-web at this URL:
https://opensource.org/licenses/AFL-3.0
If you did not receive a copy of the license and are unable to
obtain it through the world-wide-web, please send an email
to<EMAIL_ADDRESS>so we can send you a copy immediately.

DISCLAIMER

Do not edit or add to this file if you wish to upgrade PrestaShop to newer
versions in the future. If you wish to customize PrestaShop for your
needs please refer to http://www.prestashop.com for more information.

@author    PrestaShop SA<EMAIL_ADDRESS>@copyright 2007-2018 PrestaShop SA
@license   https://opensource.org/licenses/AFL-3.0 Academic Free License 3.0 (AFL-3.0)
International Registered Trademark & Property of PrestaShop SA
*}
{block name='head_charset'}

{/block}
{block name='head_ie_compatibility'}

{/block}

{block name='head_seo'}
{block name='head_seo_title'}{$page.meta.title}{/block}

  {if $page.meta.robots !== 'index'}

  {/if}
  {if $page.canonical}

  {/if}
  {block name='head_hreflang'}
      {foreach from=$urls.alternative_langs item=pageUrl key=code}

      {/foreach}
  {/block}
{/block}
{block name='head_viewport'}

{/block}
{block name='head_icons'}

{/block}
{block name='stylesheets'}
{include file="_partials/stylesheets.tpl" stylesheets=$stylesheets}
{/block}
{block name='javascript_head'}
{include file="_partials/javascript.tpl" javascript=$javascript.head vars=$js_custom_vars}
{/block}
{block name='hook_header'}
{$HOOK_HEADER nofilter}
{/block}
{block name='hook_extra'}{/block}

This is an issue you'd need to bring up with your hosting provider, it's not related to the cookie consent library which functions fine on millions of web sites.


Add the option to build without exceptions

 Thank you for your submission, we really appreciate it. Like many open source projects, we ask that you sign our Contributor License Agreement before we can accept your contribution.


Fix math scrollbars for realz

closes https://github.com/pydata/pydata-sphinx-theme/issues/1197

OK it actually looks to be fixed now: https://pydata-sphinx-theme--1198.org.readthedocs.build/en/1198/user_guide/theme-elements.html#mathematics


Small optimization.

Avoid calc strlen many times.

Checklist

[ ] documentation is added or updated
[ ] tests are added or updated

Close/reopen to kick CLA bot.

Note: Since this is a small change, feel free to just amend your commit and force-push it.  Maybe, better make a new Pull?
I don't have git in my machine. I'm using online only.
Please, feel free to commit with your changes requested.

Ok, don't worry. I'll just do the change for you and force-push it to your repo. Hang on a minute...

@raniervf I just pushed two commits:

Your original commit, with the new commit message:
5418689ba1 conf_def.c: Avoid calling strlen() in a loop

The additional fixes for VMS
970ecc6b89 fixup! conf_def.c: Avoid calling strlen() in a loop

@levitte could you please double check the VMS fix?

Thanks, looks good to me.

Not sure why this is tagged as 1.1.1

Not sure why this is tagged as 1.1.1

Well, it is not a feature, but an enhancement (a small performance improvement), and as such could be considered a bug fix. Also, it cherry-picks cleanly to 1.1.1. So it could be backported, if not for the improvement then maybe just to keep the 1.1.1 branch as close to master as possible to reduce the likelyhood of futher merge conflicts.
OTOH, I agree that it is debatable whether backporting is worth the effort, even more since there are now many more strlen() micro changes in the queue :-)

@mattcaswell do you have any objections against cherry-picking to 1.1.1?

None, My objective is improve the performance the version 1.1.1d, which i'm using.

None, My objective is improve the performance the version 1.1.1d, which i'm using.

I am very curious: have you done any profiling that shows repeated strlen is impactful?

No, I did not do, is this really necessary?
Strlen is the most famous performance killers, and any programmer should avoid using.
Compare:
str[0] != '\0' with strlen(str) > 0, what is best to use?
Nginx is the most famous example with this kind of optimization, all strings have size, no need strlen or string copy, but the example is extreme, and we are far...
Please read:
https://books.google.com.br/books?id=V1kPDAAAQBAJ&pg=PA152&lpg=PA152&dq=strlen+call+repeated&source=bl&ots=kWeIJHaX2k&sig=ACfU3U25gYfnY1WK0uOTMkM6_tsHBndt4g&hl=pt-BR&sa=X&ved=2ahUKEwjn8Pe4odvlAhVYIrkGHY-wDn8Q6AEwAXoECAkQAQ#v=onepage&q=strlen call repeated&f=false

OpenSSL is a crypto library, not a webserver; the first does lots of math, the second deals with lots of strings.  Without profiling, you don't know if this is useful or just a waste of (er) time.  Sure, it makes the code better, but is it the thing to really work on?  I don't know. Without real measurements, nobody knows in fact.

No, I did not do, is this really necessary?

No, it isn‘t. Your optimizations are standard best practices and not some tricky premature optimization, which nerds to be justified by profiling IMHO.

Funny autocorrection:  ‚nerds‘ should have been ‚needs‘.

@mattcaswell do you have any objections against cherry-picking to 1.1.1?

No objections.

Merged to master and 1.1.1. Thank you @raniervf and congratulation to your first contribution to OpenSSL!
d1c1fb2d41 conf_def.c: Avoid calling strlen() in a loop [master]
30bd3e5160 conf_def.c: Avoid calling strlen() in a loop [1.1.1]

@raniervf GitHub shows a note that the pull request was closed with an unmerged branch. It is safe to remove the branch now, in fact I recommend doing it, otherwise your pull request branches will be piling up. At least I do it, others think differently about it, YMMV.

Thank you.


Mac Version doesn't compile

I might overlook something, but the a8c1dfd version doesn't seem to compile on a Mac. UseStoreKitReviewPrompt seems to be missing. It is only declared for iOS.
#if os(iOS)
    public func useStoreKitReviewPrompt() -> Bool {
...

but it is needed elsewhere, like in shouldTryStoreKitReviewPrompt, where it says function is available for all macOS versions.
    public var shouldTryStoreKitReviewPrompt : Bool {
        if #available(iOS 10.3, *), useStoreKitReviewPrompt { return true }

Please review. Thanks for this great library.

I don't think this issue was introduced with a8c1dfd.

It was introduced on https://github.com/UrbanApps/Armchair/pull/112 by @MartinMoizard, but I haven't had time to revert it. Pull's welcome.


ctlptl: 0.8.28 -> 0.8.29

Automatic update generated by nixpkgs-update tools. This update was made based on information from https://github.com/tilt-dev/ctlptl/releases.
meta.description for ctlptl is: CLI for declaratively setting up local Kubernetes clusters
meta.homepage for ctlptl is: https://github.com/tilt-dev/ctlptl
Updates performed

Golang update

To inspect upstream changes

Release on GitHub

Compare changes on GitHub

Impact
Checks done

built on NixOS
The tests defined in passthru.tests, if any, passed
found 0.8.29 with grep in /nix/store/kw4avqrcj7yhilz68a6jimkq1q70s5yq-ctlptl-0.8.29
found 0.8.29 in filename of file in /nix/store/kw4avqrcj7yhilz68a6jimkq1q70s5yq-ctlptl-0.8.29

Rebuild report (if merged into master) (click to expand)

2 total rebuild path(s)

2 package rebuild(s)

First fifty rebuilds by attrpath

ctlptl

Instructions to test this update (click to expand)

Either download from Cachix:
nix-store -r /nix/store/kw4avqrcj7yhilz68a6jimkq1q70s5yq-ctlptl-0.8.29 \
  --option binary-caches 'https://cache.nixos.org/ https://nix-community.cachix.org/' \
  --option trusted-public-keys '
  nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=
  cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=
  '

(The Cachix cache is only trusted for this store-path realization.)
For the Cachix download to work, your user must be in the trusted-users list or you can use sudo since root is effectively trusted.
Or, build yourself:
nix-build -A ctlptl https://github.com/r-ryantm/nixpkgs/archive/46e2173897aa518b8f5bf8e58d96d167e83ebc08.tar.gz

Or:
nix build github:r-ryantm/nixpkgs/46e2173897aa518b8f5bf8e58d96d167e83ebc08#ctlptl

After you've downloaded or built it, look at the files and if there are any, run the binaries:
ls -la /nix/store/kw4avqrcj7yhilz68a6jimkq1q70s5yq-ctlptl-0.8.29
ls -la /nix/store/kw4avqrcj7yhilz68a6jimkq1q70s5yq-ctlptl-0.8.29/bin

Pre-merge build results
We have automatically built all packages that will get rebuilt due to
this change.
This gives evidence on whether the upgrade will break dependent packages.
Note sometimes packages show up as failed to build independent of the
change, simply because they are already broken on the target branch.
Result of nixpkgs-review --extra-nixpkgs-config '{ allowInsecurePredicate = x: true; }' run on x86_64-linux 1

1 package built:

ctlptl

Maintainer pings
cc @svrana for testing.

Opened #314006 to remove the unnecessary build found during testing


Introduce emptyThickness parameter

This PR fixes #164.
Adding the emptyThickness parameter caused some issues when the empty arc was thicker than the full one (the empty arc had parts rendered outside the canvas), so I had to rewrite the arc rendering logic a bit, in order to use the max thickness between the two arcs.
Furthermore, thicker empty arcs also required the full empty circle to be rendered, not only the empty part itself.
I added a new example for the different thickness parameters, but I placed it before the heavily customized circle, even though it comes after it as number 6.
Finally, I added several tests for the new functionality and fixed one that was failing on my laptop.

@monovertex - are you agree with my recent remarks?

@kottenator Yes I do. I apologize for the delay, it's been a few really busy days. I'll fix the required changes as soon as possible.

Great, I'm looking forward for it ;)
And take your time, nobody is rushing, it's OSS.

@monovertex - ping? ;)

@kottenator, I'm sorry for the really late update. Things got hectic IRL and I haven't had the time or energy to focus on anything else. Let me know if there are any other improvements you'd like me to make to this PR.

@kottenator, ping?

@kottenator, coming back for one more ping, hope you see this some day. Thank you!


Split tx-prover dependencies (binary and library)

Not for this PR, but we should separate the dependencies which are needed for the binary vs. the ones that are needed for the library. One way to do this is by introducing an executable feature, but there could be other ways as well. Let's create an issue for this.

Originally posted by @bobbinth in https://github.com/0xPolygonMiden/miden-base/pull/989#discussion_r1864690926

This issue and #975 might be address at the same time.


Replace PACKAGE_NAME with native.package_name(). [phab:D2223]

Created by fromberger at 2018-03-20 14:22:53:
The older form is considered obsolete now.

shahms accepted this revision at 2018-03-20 14:25:19

jrtom accepted this revision at 2018-03-20 14:26:01

fromberger closed via commit 44634ff6907c0cce7fdb5936fdaee80903bf3ce4 at 2018-03-20 15:14:27


Cobra update and bash completions fix

filename extensions weren't working.  kubectl create -f [tab][tab] wasn't showing .json/yaml files.  Only directories.

@jlowdermilk unsure whether you have context on conbra and bash completions—feel free to reassign elsewhere if not

lgtm. Test failure looks like flake. I kicked travis.

Hmmm, still broken: https://travis-ci.org/GoogleCloudPlatform/kubernetes/jobs/61327954 Unit test failing in pkg/client for v1beta1. Can you take a look? If you don't think this should affect it, rebasing may resolve.

Shippable green, merging.


fixes to loading config file and a few other little things

is this redundant now @cboursnell ? it's very old


DataSync Conflict server returns value using integer rather than string.

Datasync https://github.com/aerogear/graphback/blob/master/packages/graphback-datasync/src/DataSyncPlugin.ts#L83 expects it as string so it should be returned and saved as string  and not a number as in https://github.com/aerogear/graphback/blob/master/packages/graphback-core/src/utils/fieldTransformHelpers.ts#L33.

I was thinking about this. Since we have index we can ignore performance issues, but we use this as order by. @ssd71 any reason why we used number vs strings?

Comparing timestamps as strings will not work if, say I want all changes and give a lastSync value of "0", however this workaround of using numbers still feels lacking

Ah.. I think we are grand - DB can have number - feels more natural and in this case we can transform that back (as this is error and it not going to be touched by scalars etc.)

Fixed and verified


filtering out nil view controller titles: 'ARAnalyticsShouldFire' block not being called for UIViewController subclasses

I'm using the aspect-oriented DSL to setup my analytics events, and had included a snippet exactly like the one in https://github.com/orta/ARAnalytics#aspect-oriented-dsl to opt any of my UIViewController subclasses which lacked a title property out of my title-oriented tracking.
However, I'm getting runtime crashes on title being nil, and in ARDSL.m's ar_shouldFireForInstance (this code), the dictionary being passed in lacks a dictionary[ARAnalyticsShouldFire] value:
(lldb) bt
* Thread 1 (tid 0xd06659, queue "com.apple.main-thread"): 0x000000010a228cb5 ar_shouldFireForInstance(dictionary=0x00007fb688f70ac0, instance=0x00007fb68b005950, context=0x00007fb688d871b0) + 133 at ARDSL.m:22
    Stopped by breakpoint 3.1
  * #0  0x000000010a228cb5 ar_shouldFireForInstance(dictionary=0x00007fb688f70ac0, instance=0x00007fb68b005950, context=0x00007fb688d871b0) + 133 at ARDSL.m:22
    #1  0x000000010a229baa __53+[ARAnalytics(.block_descriptor=0x00007fb68b0066e0, parameters=0x00007fb688d871b0) addScreenMonitoringAnalyticsHook:]_block_invoke_4 + 106 at ARDSL.m:109
    #2  0x000000010a3edaef -[RACSubscriber sendNext:](self=0x00007fb68b006510, _cmd=0x000000010a48c6e7, value=0x00007fb688d871b0) + 239 at RACSubscriber.m:72
    #3  0x000000010a3ae1ec -[RACPassthroughSubscriber sendNext:](self=0x00007fb68b006770, _cmd=0x000000010a48c6e7, value=0x00007fb688d871b0) + 444 at RACPassthroughSubscriber.m:74
    #4  0x000000010a3ecd34 __23-[RACSubject sendNext:]_block_invoke(.block_descriptor=0x00007fff55a5ba00, subscriber=0x00007fb68b006770) + 68 at RACSubject.m:93
    #5  0x000000010a3ecb33 -[RACSubject enumerateSubscribersUsingBlock:](self=0x00007fb68b0061a0, _cmd=0x000000010a4a3184, block=0x00007fff55a5ba00) + 595 at RACSubject.m:85
    #6  0x000000010a3eccc7 -[RACSubject sendNext:](self=0x00007fb68b0061a0, _cmd=0x000000010a48c6e7, value=0x00007fb688d871b0) + 151 at RACSubject.m:92
    #7  0x000000010a39618b RACForwardInvocation(self=0x00007fb68b005950, invocation=0x00007fb688d99330) + 347 at NSObject+RACSelectorSignal.m:55
    #8  0x000000010a395f6c __RACSwizzleForwardInvocation_block_invoke(.block_descriptor=0x00007fb68b005f30, self=0x00007fb68b005950, invocation=0x00007fb688d99330) + 92 at NSObject+RACSelectorSignal.m:79
    #9  0x000000010d799f4f ___forwarding___ + 495
    #10  0x000000010d799cd8 __forwarding_prep_0___ + 120
    #11  0x000000010c30eff1 -[UIViewController _setViewAppearState:isAnimating:] + 567
    #12  0x000000010d786026 __53-[__NSArrayI enumerateObjectsWithOptions:usingBlock:]_block_invoke + 70
    #13  0x000000010d785f5c -[__NSArrayI enumerateObjectsWithOptions:usingBlock:] + 284
    #14  0x000000010c30f149 -[UIViewController _setViewAppearState:isAnimating:] + 911
    #15  0x000000010c336fb9 -[UINavigationController viewDidAppear:] + 173
    #16  0x000000010c30eff1 -[UIViewController _setViewAppearState:isAnimating:] + 567
    #17  0x000000010c349f26 -[UITabBarController viewDidAppear:] + 108
    #18  0x000000010d732dec __invoking___ + 140
    #19  0x000000010d732c42 -[NSInvocation invoke] + 290
    #20  0x000000010a39612c RACForwardInvocation(self=0x00007fb688c4dc10, invocation=0x00007fb688c9cf20) + 252 at NSObject+RACSelectorSignal.m:50
    #21  0x000000010a395f6c __RACSwizzleForwardInvocation_block_invoke(.block_descriptor=0x00007fb688f8b350, self=0x00007fb688c4dc10, invocation=0x00007fb688c9cf20) + 92 at NSObject+RACSelectorSignal.m:79
    #22  0x000000010d799f4f ___forwarding___ + 495
    #23  0x000000010d799cd8 __forwarding_prep_0___ + 120
    #24  0x000000010c30eff1 -[UIViewController _setViewAppearState:isAnimating:] + 567
    #25  0x000000010c30fb3b -[UIViewController _executeAfterAppearanceBlock] + 52
    #26  0x000000010c1fe62c _applyBlockToCFArrayCopiedToStack + 314
    #27  0x000000010c1fe4c5 _afterCACommitHandler + 564
    #28  0x000000010d76fca7 __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 23
    #29  0x000000010d76fc00 __CFRunLoopDoObservers + 368
    #30  0x000000010d765a33 __CFRunLoopRun + 1123
    #31  0x000000010d765366 CFRunLoopRunSpecific + 470
    #32  0x000000010f920a3e GSEventRunModal + 161
    #33  0x000000010c1da900 UIApplicationMain + 1282
    #34  0x000000010a1d102f main(argc=1, argv=0x00007fff55a5d358) + 111 at main.m:14
    #35  0x000000010e464145 start + 1
    #36  0x000000010e464145 start + 1
(lldb) po dictionary
{
    keypath = title;
}

(lldb) po instance
<BoldPostTableViewController: 0x7fb68b005950>

(lldb) po [instance title]
 nil

I was under the impression (perhaps wrongly) that this configuration would apply to all subclasses of UIViewController. (This is taken more or less verbatim from the readme for ARAnalytics.)
configuration: @{
	ARAnalyticsTrackedScreens: @[ @{
		ARAnalyticsClass: UIViewController.class,
		ARAnalyticsDetails: @[ @{
			ARAnalyticsPageNameKeyPath: @"title",
		}],
		ARAnalyticsShouldFire:
		^BOOL(UIViewController *controller, NSArray *parameters) {
			if ( nil == controller.title ) {
				NSLog(@"%s controller %@ has no title!", __func__, controller);
			}
			return controller.title != nil;
		},
…

Hmm. Sorry about that @cbowns.
Taking a look, it appears that the ARAnalyticsShouldFire key/value pair should be inside the ARAnalyticsDetails. This lets you have per-event firing filtering behaviour. In the code you've posted above, ARAnalytics doesn't see the should fire block and assumes there isn't one.
Please let us know if this helps.
(Side note: this is actually a weakness of the DSL – you are not the first person to have this issue. In fact, I made the mistake myself a few weeks ago. @kylef has suggested moving away from arrays/dictionaries. Maybe we can use Swift? Open to suggestions.)

Oh, that makes sense! I simply didn't read the DSL examples that closely, and Xcode's default formatting made it difficult to see the scope of what I'd added. That fixed it, thanks.

:+1:


Superposition of translucent shapes yields wrong values

I generate a <Svg> component consisting of overlaid shapes with different fillOpacity, and I get access to the pixel data using the toDataURL method. It all works fine, until I read the values and I realize that the superposition is not working as expected.
Here is a snack of the issue:
https://snack.expo.io/@ksesong/sum-of-translucent-shapes
(Instructions: After changing the fillOpacity values, I copy the resulting logged base64 code as an image, and I read the pixel value on an image editor)
When I write the same svg on a classic html file, I always get the expected values (see: https://codepen.io/anon/pen/REKMYx)
I've drawn a quick schematic of the expected/actual values. (A, B, and C refer to different sets of parameters.)

(I also used react-native-view-shot to get the snapshot of the view, and it yielded the same result).

Check e.g. https://twitter.com/kzzzf/status/1075450658050977792


QueueTransformer incorrectly restores queues

When restoring Queue the transformer restores the internal fields _size, _head, _tail based on the number of elements. The field _tail is set to _size but should be set to _size - 1.

Done


Issue with :notify_url in documentation

The documentation in the read me says to use :notify_url, when it is actually :ipn_notification_url.

Fixed here 4022d7ba72, Thank you!


Why is the order of the documents unstable?

I was writing integration tests for a project that uses tantivy,
and I noticed that writes in the same order produced different sequential results after commit,
which actually broke my test cases...
code:
writer.add_document(doc1);
writer.add_document(doc2);
writer.commit().unwrap();

let searcher = reader.searcher();
println!("{:?}", schema.to_named_doc(&searcher.doc(DocAddress::new(0, 0)).unwrap()));
println!("{:?}", schema.to_named_doc(&searcher.doc(DocAddress::new(1, 0)).unwrap()));

output:
// case 1
NamedFieldDocument({"_id": [Str("1")], "text": [Str("hello world")]})
NamedFieldDocument({"_id": [Str("2")], "text": [Str("bye world")]})

// case 2
NamedFieldDocument({"_id": [Str("2")], "text": [Str("bye world")]})
NamedFieldDocument({"_id": [Str("1")], "text": [Str("hello world")]})

The output seems random, is there a reason for this?

Multithreading. By default tantivy uses more than one thread for indexing. It is not necessarily a good idea.
You can create a single threaded writer to avoid that.
I forgot the name of the method in Index.

Thanks, using writer_with_num_threads does solve this.


Update or remove 11ty peer dependency

When bumping to the latest 11ty over at the Stacks repo, this breaks the build since eleventy-plugin-highlightjs is expecting 0.11.1. This peer dependency locks anyone depending on this plugin to be at that explicit version number. Had a look at some various plugins and no one seems to mess with 11ty as a dependency.
👀
https://github.com/ogdenstudios/eleventy-plugin-markdown-shortcode/blob/master/package.json
https://github.com/JordanShurmer/eleventy-plugin-nesting-toc/blob/master/package.json

Fixed in #5


Introduce a path argument

Suggested specification

Optional, with the default being the current directory
arg: -d, alias: --directory
Must support relative paths: --directory ../../path/to/project, or -d ../../path/to/project/
Should support absolute paths (though I am unsure of the consequences within various CIs): --path /home/<PATH>/
If an NPM package is not found at that path, it should exit with and error code

Introducing a relative path could potentially be useful for lerna projects, where the CI will perform multiple audits. It could also be useful for introducing audit-ci into scripts, where the script can reside anywhere.

The path argument cannot be used now since I used it for --package-manager. To avoid misunderstanding, there will be no single letter arg, only --path.

Fixed in #53 (uses the --directory argument)


Operator with engine CUDNN is not available for operator Relu

caffe2 build seems to have gone ok. But when I run the test:
python -m caffe2.python.operator_test.relu_op_test
I get errors saying:
Operator with engine CUDNN is not available for operator Relu
Operator with engine CUDNN is not available for operator ReluGradient
...
The build can find cuDNN and I have the correct path set in my LD_LIRBRARY_PATH. Any other ideas of why I would get these errors?
System information

Operating system: CentOS
Compiler version: 4.8.5
CMake version: cmake3
CMake arguments:
Relevant libraries/versions (e.g. CUDA): cuda 9.0, cuDNN 7.0.5

CMake summary output
-- Does not need to define long separately.
-- Current compiler supports avx2 extention. Will build perfkernels.
-- Caffe2: Found protobuf with old-style protobuf targets.
-- Caffe2 protobuf include directory: /usr/include
-- The BLAS backend of choice:Eigen
-- Found NNPACK      (include: /usr/local/include, library: /usr/local/lib64/libnnpack.a)
-- Found PTHREADPOOL (library: /usr/local/lib64/libpthreadpool.a)
-- Found CPUINFO     (library: /usr/local/lib64/libcpuinfo.a)
INFOFound external NNPACK installation.
-- Caffe2: Found gflags with new-style gflags target.
-- Caffe2: Found glog with new-style glog target.
-- Found PythonInterp: /data/miniconda/bin/python (found version "2.7.14")
-- git Version: v0.0.0-dirty
-- Version: 0.0.0
-- Performing Test HAVE_STD_REGEX
-- Performing Test HAVE_STD_REGEX
-- Performing Test HAVE_STD_REGEX -- compiled but failed to run
-- Performing Test HAVE_GNU_POSIX_REGEX
-- Performing Test HAVE_GNU_POSIX_REGEX
-- Performing Test HAVE_GNU_POSIX_REGEX -- failed to compile
-- Performing Test HAVE_POSIX_REGEX
-- Performing Test HAVE_POSIX_REGEX
-- Performing Test HAVE_POSIX_REGEX -- success
-- Performing Test HAVE_STEADY_CLOCK
-- Performing Test HAVE_STEADY_CLOCK
-- Performing Test HAVE_STEADY_CLOCK -- success
-- Found lmdb    (include: /usr/include, library: /usr/lib64/liblmdb.so)
-- Found LevelDB (include: /usr/include, library: /usr/lib64/libleveldb.so)
-- Found Snappy  (include: /usr/include, library: /usr/lib64/libsnappy.so)
CMake Warning at cmake/Dependencies.cmake:222 (message):
Not compiling with OpenCV.  Suppress this warning with -DUSE_OPENCV=OFF
Call Stack (most recent call first):
CMakeLists.txt:101 (include)
CMake Warning at cmake/Dependencies.cmake:243 (find_package):
By not providing "FindEigen3.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "Eigen3", but
CMake did not find one.
Could not find a package configuration file provided by "Eigen3" with any
of the following names:
Eigen3Config.cmake
eigen3-config.cmake

Add the installation prefix of "Eigen3" to CMAKE_PREFIX_PATH or set
"Eigen3_DIR" to a directory containing one of the above files.  If "Eigen3"
provides a separate development package or SDK, be sure it has been
installed.
Call Stack (most recent call first):
CMakeLists.txt:101 (include)
-- Did not find system Eigen. Using third party subdirectory.
-- Found PythonInterp: /data/miniconda/bin/python (found suitable version "2.7.14", minimum required is "2.7")
-- NumPy ver. 1.14.0 found (include: /data/miniconda/lib/python2.7/site-packages/numpy/core/include)
-- Could NOT find pybind11 (missing:  pybind11_INCLUDE_DIR)
-- Could NOT find MPI_C (missing:  MPI_C_LIBRARIES MPI_C_INCLUDE_PATH)
-- Could NOT find MPI_CXX (missing:  MPI_CXX_LIBRARIES MPI_CXX_INCLUDE_PATH)
CMake Warning at cmake/Dependencies.cmake:302 (message):
Not compiling with MPI.  Suppress this warning with -DUSE_MPI=OFF
Call Stack (most recent call first):
CMakeLists.txt:101 (include)
-- Caffe2: CUDA detected: 9.0
-- Found cuDNN: v7.0.5  (include: /usr/local/cuda/include, library: /usr/local/cuda/lib64/libcudnn.so)
-- Automatic GPU detection returned 6.1 6.1.
-- Added CUDA NVCC flags for: sm_61
-- Could NOT find NCCL (missing:  NCCL_INCLUDE_DIRS NCCL_LIBRARIES)
-- Could NOT find CUB (missing:  CUB_INCLUDE_DIR)
-- Could NOT find Gloo (missing:  Gloo_INCLUDE_DIR Gloo_LIBRARY)
-- CUDA detected: 9.0
-- Found libcuda: /usr/lib64/libcuda.so
-- Found libnvrtc: /usr/local/cuda/lib64/libnvrtc.so
CMake Warning at cmake/Dependencies.cmake:430 (message):
mobile opengl is only used in android or ios builds.
Call Stack (most recent call first):
CMakeLists.txt:101 (include)
CMake Warning at cmake/Dependencies.cmake:506 (message):
Metal is only used in ios builds.
Call Stack (most recent call first):
CMakeLists.txt:101 (include)
-- GCC 4.8.5: Adding gcc and gcc_s libs to link line
-- Include NCCL operators
-- Excluding image processing operators due to no opencv
-- Excluding video processing operators due to no opencv
-- Excluding mkl operators as we are not using mkl
-- MPI operators skipped due to no MPI support
-- Include Observer library
-- Using lib/python2.7/site-packages as python relative installation path
-- Automatically generating missing init.py files.
 I am not sure where to add them to a CMakeList or that sort of file?

Ok, that is good to know. It still doesn't solve the problem that when I run cmake3 .. in the build directory it says it can't find nccl, gloo, eigen, etc even though they are present in the third_party directory. I downloaded a fresh copy of caffe2 with the --recursive flag.

Hello, I compiled Caffe2 with Cuda8.0 and Cudnn6.0.5 successfully. But when I run mnist.ipynb in the tutorial directory. It prints out Operator with engine CUDNN is not available for operator Conv.
It's quite weird since I have compiled Caffe2 with Cudnn. Should the basic conv operator still have no support from CUDNN?

@dreamk73 download all of them individually and place them in the third party folder

The problem is not that the files are not downloaded. They are present in the third_party directory already. The problem is that when I run cmake it doesn't include these files or says it can't find them.

Show the error
Regards
Himank Maan
On 16-Mar-2018 12:59 PM, "Esther Judd-Klabbers"<EMAIL_ADDRESS>wrote:

The problem is not that the files are not downloaded. They are present in
the third_party directory already. The problem is that when I run cmake it
doesn't include these files or says it can't find them.
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
https://github.com/caffe2/caffe2/issues/2130#issuecomment-373626977, or mute
the thread
https://github.com/notifications/unsubscribe-auth/AZZTzMlBAXjvW1GsDEZldo9BXFOvF4mqks5te2nbgaJpZM4SbwVW
.

@bddppq You mean that when we get this warning for example Engine CUDNN is not available for operator MaxPool, it means that CUDNN does not have MaxPool operator ?

Hi @huangh12 ,
were you able to use engine CUDNN for the operator Conv?


Appstudio update mvp-test-component

Pipelines as Code configuration proposal

Pipelines as Code CI/mvp-test-component-on-pull-request has successfully validated your commit.

StatusDurationName

✅ Succeeded
9 seconds
init

✅ Succeeded
17 seconds
clone-repository

✅ Succeeded
1 minute
build-container

✅ Succeeded
22 seconds
sanity-inspect-image

✅ Succeeded
21 seconds
deprecated-base-image-check

✅ Succeeded
28 seconds
sbom-json-check

✅ Succeeded
1 minute
clamav-scan

✅ Succeeded
3 minutes
clair-scan

✅ Succeeded
19 seconds
sanity-optional-label-check

✅ Succeeded
16 seconds
sanity-label-check

✅ Succeeded
12 seconds
show-summary


Various signal errors in editor, related to TileMap [3.2.4-rc2]

Godot version:
3.2.4.rc2.official
OS/device including version:
Ubuntu Linux 20.04
Issue description:
In the editor, when loading a scene that contains TileMaps - or adding a TileMap to an existing scene - 9 identical errors are written to the console:
 core/object.cpp:1257 - Error calling method from signal 'timeout': 'SceneTreeEditor::_update_tree': Method expected 1 arguments, but called with 0..

When deleting a TileMap, this error is printed twice:
 Attempt to disconnect a nonexistent connection to signal 'idle_frame' in [SceneTree:1228], with target '_on_workspace_process' in [TileSetEditor:15462].

Steps to reproduce:
As above.
Minimal reproduction project:
n/a

same issue with popup node

Can reproduce this bug up to this commit 1b9a01948e9f0470f4532c2de399a08b8b15f0b5.
https://github.com/godotengine/godot/blob/1b9a01948e9f0470f4532c2de399a08b8b15f0b5/editor/scene_tree_editor.cpp#L1231
A timeout signal is connected to SceneTreeEditor::_update_tree() which now takes an optional parameter:
https://github.com/godotengine/godot/blob/1b9a01948e9f0470f4532c2de399a08b8b15f0b5/editor/scene_tree_editor.h#L77
It looks like the connection should look like this:
update_timer->connect("timeout", this, "_update_tree", varray(false));

When deleting a TileMap, this error is printed twice:
 Attempt to disconnect a nonexistent connection to signal 'idle_frame' in [SceneTree:1228], with target '_on_workspace_process' in [TileSetEditor:15462].

This isn't fixed, still happens in the 3.3.stable.


Only zeros

When I read from the sensor I only have zeros. I set the baud rate in /boot/config.txt:
dtparam=i2c_baudrate=400000
What do I need to do on a fresh RPI?

@tnorlund if you managed to solve your issue, can you maybe share what the problem was?


Add syntax highlighting to README.md examples

The diff is pretty useless. You can see what the README looks like in my branch here.

Wonderful, thanks!


KINDLING File Size calculation and reporting

Title of ticket:
Description
As advised by @lmullane analyzed the size of KINDLING file storage, data growth and other information related to Kindling storage.
Dependencies
Are there any dependencies?
DOD

[x] Develop a PowerShell script to take data ranges and project the total file sizes for the files created on kindling shared location between those dates
[x]  Execute the scripts between various date ranges and tabulate the data
[x]  Present to Team
[ ]
[ ]

https://bcgov.sharepoint.com/:x:/r/teams/03521/Shared Documents/Testing/KINDLING SIZE tabulation.xlsx?d=wa8a8333d1b8c44de8f35a9cee7b313d2&csf=1&web=1&e=b4eaWD
https://bcgov.sharepoint.com/:w:/r/teams/03521/Shared Documents/Testing/KINDLING SIZE.docx?d=w9dbbda130d594f5ca92059dc9a03c45f&csf=1&web=1&e=7vhiq7
Reports and tabulation - @lmullane  , @m-prodan , @liseandtea , @KyEggleston


Enable restarting of running processes

Closes https://github.com/Qard/onchange/issues/28, https://github.com/Qard/onchange/issues/25 and https://github.com/Qard/onchange/issues/22.

Nice, thanks! I'll review this tonight. :smile_cat:

@blakeembrey @Qard Any updates on this?

Sorry, forgot about this...I haven't really used onchange for anything lately, so it's not exactly at the top of my mind.
@blakeembrey Want commit/publish access. I'm not really doing a great job of maintaining this myself.

@Qard Sure, I can help provide updates and issue maintenance :+1:

I gave you push access to this repo and publish access on npm. Thanks for the help! :smile_cat:

Thanks, I'll merge what's here and do a release. If I come back around, we can see if there's a chance of getting tests in too :smile:


@bind-Settings on DataGrid cause infinite loop as issue #800

Hello,
I encounter the same problem as Kastroph.
And the demo on https://blazor.radzen.com/datagrid-save-settings-loaddata is stuck in the same loop.
Best regards
          We have the same issue.

          I have replicated our datagrid as much as possible with the demo code. But have been unable to replicate the issue.

          I have attached a gif of the behaviour

Originally posted by @kastroph in https://github.com/radzenhq/radzen-blazor/issues/800#issuecomment-1426699955

We've updated the demo to avoid such problems. You can check the latest code for reference.

Hello, I still encounter the issue even on demo.
The loading indicator never desappear.

After few secondes my browser says me that the website doesn't respond


Is it possible to use different backbone (without sharing parameters) for training SSL ?

Amazing repo for SSL. Great work guys! I would like to know where to change so that I can pass the input images to different backbones (like 1 image in Resnet50 and other augmented images in ResNet18). Thank you!

Thanks. And it would be great if you could add VICReg  training with different backbones and without sharing parameters for supporting multi-modal inputs as that would be a great addition to the repo.

Yes, it would be nice, but it requires a lot of work and I am not sure we can generalize our current design without completely turning the repository upside down


fix: Orchestrator don't show notification if model already exists

Description
The download model notification pops whenever we use Orchestrator, even when not necessary.  This is a minor fix to not show the notification unless the model download is actually started.
Task Item
#minor

Coverage decreased (-0.01%) to 52.95% when pulling 0e5d54fba454c62ffe6c81c2b2d6260270629e12 on tachou/orchNotificationFix into 26c76f1fe446c0bee65ee3b0b0eb72db27f1c24b on main.


How can I validate a user through an application API?

I have built an application that apart from user frontend, it provides also an API alternative for the same functionality. Is there a way to forward a given username and password to the flask-user manager for validation? I was looking at the login() function inside views.py and whole login logic seems hard-coded in the view with no obvious way to reuse it.

Greetings,
If I understand your question correctly, you want to be able to programmatically log a user in without going through the login form?
Flask-User uses Flask-Login for the meat of the login process, which requires the user model.
Here is where we call Flask-Login, login_user:
https://github.com/lingthio/Flask-User/blob/master/flask_user/views.py#L718
And here is the Flask-Login login_user function:
https://github.com/maxcountryman/flask-login/blob/master/flask_login.py#L681
So if you can send login_user the user model object of a given username and password, it should log the user into your app.

Greetings u2,
I want a user to perform authentication using the Api. This means that I have to validate the username and password and not just inject a user object as the logged on user. The code you mentioned does the half job, but I have to copy paste the logic in the view of the Api.
For example all this logic from the login() and its dependencies are needed
user = None
user_email = None
if user_manager.enable_username:
# Find user record by username
user = user_manager.find_user_by_username(login_form.username.data)
user_email = None
# Find primary user_email record
if user and db_adapter.UserEmailClass:
user_email = db_adapter.find_first_object(db_adapter.UserEmailClass,
user_id=int(user.get_id()),
is_primary=True,
)
# Find user record by email (with form.username)
if not user and user_manager.enable_email:
user, user_email = user_manager.find_user_by_email(login_form.username.data)
else:
# Find user by email (with form.email)
user, user_email = user_manager.find_user_by_email(login_form.email.data)
if user:
# Log user in
return _do_login_user(user, login_form.next.data, login_form.remember_me.data)

The proposed functions you said, as far as I can understand are used after the authentication procedure.

Generally speaking when authenticating a user through a RESTful API requires the generation of an API key that is linked to the user.
It seems as though it would be easier and more secure to pass around an API key rather than a username and password.
All you'd have to do is create an API key generator and associate a key with a user, then authenticate the API key rather than the username/password.
an API key is beyond the scope of Flask-User, but could easily be extended.

I am familiar with this methodology (using API keys). But I don't want to solve the problem of different web applications working together. I am trying to use the authentication mechanism of Flask-User to crate a single-page application with angularjs. So the end user of the API will be the real user and the only valid authentication mechanism is by using its username and password.

Could you do something like this
from flask.ext.login import login_user
# flask-user user_manager instance for app
from .ext import user_manager

def custom_login(password, username=None, email=None):
    user = None
    if email:
        user = user_manager.find_user_by_email(email)
    elif username:
        user = user_manager.find_user_by_username(username)

    if not user:
        return False

    if not user_manager.verify_password(password, user):
        return False

    return login_user(user, remember=True)

@neurosnap : Thanks for jumping in!
@sque : Did neurosnap's proposal work for you?

nice.

@neurosnap thanks! I'm working on something like this, and I found that some things are slightly different in 2017 due to code changes and depreciations. So the updated snippet is this:
# Instead of flask.ext.login, which is deprecated
from flask_login import login_user
# Import your Flask app from wherever you construct it.
from my_app import app

def custom_login(password, username=None, email=None):
    user = None
    if email:
        user = app.user_manager.find_user_by_email(email)
    elif username:
        user = app.user_manager.find_user_by_username(username)

    if user is None:
        return False

    # 'user' is a tuplet now, with the user object being item 0.
    if not app.user_manager.verify_password(password, user[0]):
        return False

    return login_user(user[0], remember=True)


ModuleNotFoundError: No module named 'wav2letter' after running bash asr-install.sh

How to reproduce
Open a colab notebook
Run:
!pip install pororo

Then run:
!git clone https://github.com/kakaobrain/pororo.git

import os
os.chdir('pororo')

Then:
!bash asr-install.sh

Then upload an audio file or reference it from Google Drive by mounting google drive (click folder icon to the left then click the folder with the Drive logo on it):
from pororo import Pororo

asr = Pororo(task="asr", lang="en")
transcript = asr('/content/drive/MyDrive/test.wav')

which gives this error even though wav2letter seems to be installed:

---------------------------------------------------------------------------
ModuleNotFoundError                       Traceback (most recent call last)
<ipython-input-7-2d02aeba890c> in <module>()
      1 from pororo import Pororo
      2
----> 3 asr = Pororo(task="asr", lang="en")
      4 transcript = asr('/content/drive/MyDrive/test.wav')
      5 transcript

3 frames
/content/pororo/pororo/pororo.py in __new__(cls, task, lang, model, **kwargs)
    201             model,
    202             **kwargs,
--> 203         ).load(device)
    204
    205         return task_module

/content/pororo/pororo/tasks/automatic_speech_recognition.py in load(self, device)
    103                 'Support Languages : ["ko", "en", "zh"]',
    104             )
--> 105         from pororo.models.wav2vec2.recognizer import BrainWav2Vec2Recognizer
    106
    107         model_path = download_or_load(

/content/pororo/pororo/models/wav2vec2/recognizer.py in <module>()
     13
     14 from pororo.models.vad import VoiceActivityDetection
---> 15 from pororo.models.wav2vec2.submodules import (
     16     BrainWav2VecCtc,
     17     W2lViterbiDecoder,

/content/pororo/pororo/models/wav2vec2/submodules.py in <module>()
     13 )
     14 from fairseq.tasks.audio_pretraining import AudioPretrainingTask
---> 15 from wav2letter.criterion import CpuViterbiPath, get_data_ptr_as_bytes
     16 from wav2letter.decoder import CriterionType
     17

ModuleNotFoundError: No module named 'wav2letter'

---------------------------------------------------------------------------
NOTE: If your import is failing due to a missing package, you can
manually install dependencies using either !pip or !apt.

To view examples of installing some common dependencies, click the
"Open Examples" button below.
---------------------------------------------------------------------------

Environment

OS : Colab
Python version : 3.6
CPU/GPU : GPU

It seems that the wav2letter has not been installed. Show me the error when you ran the wav2letter installation command.

Oh when I ran this command !bash asr-install.sh, I got this (don't have the first time I ran it, as I tried to run it once more after I got the error above):
OSTYPE: linux-gnu
Requirement already satisfied: soundfile in /usr/local/lib/python3.6/dist-packages (0.10.2)
Requirement already satisfied: torchaudio==0.6.0 in /usr/local/lib/python3.6/dist-packages (0.6.0)
Requirement already satisfied: cffi>=1.0 in /usr/local/lib/python3.6/dist-packages (from soundfile) (1.14.4)
Requirement already satisfied: torch==1.6.0 in /usr/local/lib/python3.6/dist-packages (from torchaudio==0.6.0) (1.6.0)
Requirement already satisfied: pycparser in /usr/local/lib/python3.6/dist-packages (from cffi>=1.0->soundfile) (2.20)
Requirement already satisfied: numpy in /usr/local/lib/python3.6/dist-packages (from torch==1.6.0->torchaudio==0.6.0) (1.19.5)
Requirement already satisfied: future in /usr/local/lib/python3.6/dist-packages (from torch==1.6.0->torchaudio==0.6.0) (0.16.0)
asr-install.sh: line 25: conda: command not found
Requirement already satisfied: pydub in /usr/local/lib/python3.6/dist-packages (0.24.1)
Requirement already satisfied: editdistance==0.5.3 in /usr/local/lib/python3.6/dist-packages (0.5.3)
Requirement already satisfied: SoundFile==0.10.2 in /usr/local/lib/python3.6/dist-packages (0.10.2)
Requirement already satisfied: numba==0.48 in /usr/local/lib/python3.6/dist-packages (0.48.0)
Requirement already satisfied: cffi>=1.0 in /usr/local/lib/python3.6/dist-packages (from SoundFile==0.10.2) (1.14.4)
Requirement already satisfied: numpy>=1.15 in /usr/local/lib/python3.6/dist-packages (from numba==0.48) (1.19.5)
Requirement already satisfied: llvmlite<0.32.0,>=0.31.0dev0 in /usr/local/lib/python3.6/dist-packages (from numba==0.48) (0.31.0)
Requirement already satisfied: setuptools in /usr/local/lib/python3.6/dist-packages (from numba==0.48) (53.0.0)
Requirement already satisfied: pycparser in /usr/local/lib/python3.6/dist-packages (from cffi>=1.0->SoundFile==0.10.2) (2.20)
Hit:1 https://cloud.r-project.org/bin/linux/ubuntu bionic-cran40/ InRelease
Ign:2 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64  InRelease
Hit:3 http://security.ubuntu.com/ubuntu bionic-security InRelease
Hit:4 http://archive.ubuntu.com/ubuntu bionic InRelease
Ign:5 https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1804/x86_64  InRelease
Hit:6 https://developer.download.nvidia.com/compute/cuda/repos/ubuntu1804/x86_64  Release
Hit:7 https://developer.download.nvidia.com/compute/machine-learning/repos/ubuntu1804/x86_64  Release
Hit:8 http://archive.ubuntu.com/ubuntu bionic-updates InRelease
Hit:9 http://ppa.launchpad.net/c2d4u.team/c2d4u4.0+/ubuntu bionic InRelease
Hit:10 http://archive.ubuntu.com/ubuntu bionic-backports InRelease
Hit:11 http://ppa.launchpad.net/cran/libgit2/ubuntu bionic InRelease
Hit:12 http://ppa.launchpad.net/graphics-drivers/ppa/ubuntu bionic InRelease
Reading package lists... Done
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  libcublas-dev libcublas10 libcudnn7 libcudnn7-dev libnccl-dev libnccl2
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
Note, selecting 'libsndfile1-dev' instead of 'libsndfile-dev'
apt-utils is already the newest version (1.6.12ubuntu0.2).
gcc is already the newest version (4:7.4.0-1ubuntu2.3).
libpq-dev is already the newest version (10.15-0ubuntu<IP_ADDRESS>).
libsndfile1-dev is already the newest version (1.0.28-4ubuntu<IP_ADDRESS>).
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
build-essential is already the newest version (12.4ubuntu1).
libfftw3-dev is already the newest version (3.3.7-1).
liblzma-dev is already the newest version (5.2.2-1.3).
libatlas-base-dev is already the newest version (3.10.3-5).
cmake is already the newest version (3.10.2-1ubuntu<IP_ADDRESS>).
libbz2-dev is already the newest version (1.0.6-8.1ubuntu0.2).
libzstd-dev is already the newest version (1.3.3+dfsg-2ubuntu1.1).
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
Reading package lists... Done
Building dependency tree
Reading state information... Done
build-essential is already the newest version (12.4ubuntu1).
libboost-program-options-dev is already the newest version (<IP_ADDRESS>ubuntu1).
libboost-system-dev is already the newest version (<IP_ADDRESS>ubuntu1).
libboost-thread-dev is already the newest version (<IP_ADDRESS>ubuntu1).
liblzma-dev is already the newest version (5.2.2-1.3).
zlib1g-dev is already the newest version (1:1.2.11.dfsg-0ubuntu2).
libboost-test-dev is already the newest version (<IP_ADDRESS>ubuntu1).
libeigen3-dev is already the newest version (3.3.4-4).
cmake is already the newest version (3.10.2-1ubuntu<IP_ADDRESS>).
libbz2-dev is already the newest version (1.0.6-8.1ubuntu0.2).
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
fatal: destination path 'kenlm' already exists and is not an empty directory.
 Done
Building dependency tree
Reading state information... Done
libfftw3-dev is already the newest version (3.3.7-1).
libgflags-dev is already the newest version (2.2.1-1).
libgoogle-glog-dev is already the newest version (0.3.5-1).
libopenblas-dev is already the newest version (0.2.20+ds-4).
libsndfile1-dev is already the newest version (1.0.28-4ubuntu<IP_ADDRESS>).
0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded.
fatal: destination path 'wav2letter' already exists and is not an empty directory.
Obtaining file:///root/wav2letter/bindings/python
Installing collected packages: wav2letter
  Found existing installation: wav2letter 0.0.2
    Can't uninstall 'wav2letter'. No files were found to uninstall.
  Running setup.py develop for wav2letter
Successfully installed wav2letter

When I run:
!pip install wav2letter

I get:
Requirement already satisfied: wav2letter in /root/wav2letter/bindings/python (0.0.2)

'''python
from wav2letter.criterion import CpuViterbiPath
'''
It works?

이 문제 혹시 해결하셨나요?
저도 동일문제를 겪고 있는데 어떻게 해결해야할지 모르겠어서 질문드립니다.


[Datatables] Data is not retrieved when error is checked for null

After the data is being retrieved, an unknown error is logged in the console
Sample code
function getAllDepartments () (int, errors:TypeCastError){
    int i = 0;
    sql:Parameter[] parameters = [];
    datatable df;
    errors:TypeCastError err;
    sql:ClientConnector connectorInstance = connectorInit:init();
    df = sql:ClientConnector.select (connectorInstance, "select * from departments", parameters);
    while (datatables:hasNext(df)) {
        any para = datatables:next(df);
        Department dep;
        dep, err = (Department)para;
        if (err == null){
            system:println(dep.dept_no + dep.dept_name);
            system:println(".................");
            i = i+1;
        }
        else{
            errors:getStackTrace((errors:Error)err);
            err = {msg:"Error in retrieving data from departments"};
        }

    }
    return i, err;
}

This issue is fixed in 0.91 release.


[REQUEST] Add console and highlighter parameters to tqdm wrapper.

How would you improve Rich?
Add console and highlighter parameters to tqdm wrapper.
What problem does it solve for you?
https://github.com/willmcgugan/rich/discussions/1765
Did I help
If I was able to resolve your problem, consider sponsoring my work on Rich, or buy me a coffee to say thanks.

oh, the wrapper is in tqdm project:

https://github.com/tqdm/tqdm/pull/1282

so, nevermind here :)


Video pausing and possibly unmounting when navigating away from screen using react navigation (but not pausing on iOS)

Bug

On android when I navigate to another screen (using stack navigator or bottom tab navigator.  But on iOS, when I navigate away to another screen (with no video), the video is still playing in the background.
This is the behavior I would like (on iOS) as I want to resume video when going back to the video screens (I handle pause/play with on focus/blur events in react navigation).
Is there anyway to have the same behavior on android ?
Platform

Which player are you experiencing the problem on:

Android ExoPlayer

Environment info

React native info output:
System:
    OS: Windows 10 10.0.19042
    CPU: (12) x64 AMD Ryzen 5 3600 6-Core Processor
    Memory: 3.50 GB / 15.95 GB
  Binaries:
    Node: 14.16.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.10 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 6.14.11 - C:\Program Files\nodejs\npm.CMD
    Watchman: Not Found
  SDKs:
    Android SDK: Not Found
    Windows SDK: Not Found
  IDEs:
    Android Studio: Version  <IP_ADDRESS> AI-201.87<IP_ADDRESS>99119
    Visual Studio: Not Found
  Languages:
    Java: Not Found
    Python: 3.9.2
  npmPackages:
    @react-native-community/cli: Not Found
    react: 16.13.1 => 16.13.1
    react-native: ~0.63.3 => 0.63.4
    react-native-windows: Not Found
  npmGlobalPackages:
    *react-native*: Not Found

Library version: 5.1.1
Steps To Reproduce

...
Expected behaviour

I want the video to keep playing when navigating away from the screen (like on iOS)

Reproducible sample code

link to reproductible demo : https://github.com/qhoarau/ReactNativeVideoBugDemo
Video sample
If possible, include a link to the video that has the problem that can be streamed or downloaded from.

Hey I too faced the same problem actually in my case i was using nested stack navigator inside bottom navigation
I dont know the reason tho , but figured it out it was due to that only, so I moved my audio component in the screen which was actually the root child for the bottom navigator as my player was initially in the nested stack.

Bug
On android when I navigate to another screen (using stack navigator or bottom tab navigator.  But on iOS, when I navigate away to another screen (with no video), the video is still playing in the background.
This is the behavior I would like (on iOS) as I want to resume video when going back to the video screens (I handle pause/play with on focus/blur events in react navigation).
Is there anyway to have the same behavior on android ?
Platform
Which player are you experiencing the problem on:

Android ExoPlayer

Environment info
React native info output:
System:
    OS: Windows 10 10.0.19042
    CPU: (12) x64 AMD Ryzen 5 3600 6-Core Processor
    Memory: 3.50 GB / 15.95 GB
  Binaries:
    Node: 14.16.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.10 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 6.14.11 - C:\Program Files\nodejs\npm.CMD
    Watchman: Not Found
  SDKs:
    Android SDK: Not Found
    Windows SDK: Not Found
  IDEs:
    Android Studio: Version  <IP_ADDRESS> AI-201.87<IP_ADDRESS>99119
    Visual Studio: Not Found
  Languages:
    Java: Not Found
    Python: 3.9.2
  npmPackages:
    @react-native-community/cli: Not Found
    react: 16.13.1 => 16.13.1
    react-native: ~0.63.3 => 0.63.4
    react-native-windows: Not Found
  npmGlobalPackages:
    *react-native*: Not Found

Library version: 5.1.1
Steps To Reproduce
...
Expected behaviour

I want the video to keep playing when navigating away from the screen (like on iOS)

Reproducible sample code
Video sample
If possible, include a link to the video that has the problem that can be streamed or downloaded from.

Hey I too faced the same problem actually in my case i was using nested stack navigator inside bottom navigation
I dont know the reason tho , but figured it out it was due to that only, so I moved my audio component in the screen which was actually the root child for the bottom navigator as my player was initially in the nested stack.

Bug
On android when I navigate to another screen (using stack navigator or bottom tab navigator.  But on iOS, when I navigate away to another screen (with no video), the video is still playing in the background.
This is the behavior I would like (on iOS) as I want to resume video when going back to the video screens (I handle pause/play with on focus/blur events in react navigation).
Is there anyway to have the same behavior on android ?
Platform
Which player are you experiencing the problem on:

Android ExoPlayer

Environment info
React native info output:
System:
    OS: Windows 10 10.0.19042
    CPU: (12) x64 AMD Ryzen 5 3600 6-Core Processor
    Memory: 3.50 GB / 15.95 GB
  Binaries:
    Node: 14.16.0 - C:\Program Files\nodejs\node.EXE
    Yarn: 1.22.10 - ~\AppData\Roaming\npm\yarn.CMD
    npm: 6.14.11 - C:\Program Files\nodejs\npm.CMD
    Watchman: Not Found
  SDKs:
    Android SDK: Not Found
    Windows SDK: Not Found
  IDEs:
    Android Studio: Version  <IP_ADDRESS> AI-201.87<IP_ADDRESS>99119
    Visual Studio: Not Found
  Languages:
    Java: Not Found
    Python: 3.9.2
  npmPackages:
    @react-native-community/cli: Not Found
    react: 16.13.1 => 16.13.1
    react-native: ~0.63.3 => 0.63.4
    react-native-windows: Not Found
  npmGlobalPackages:
    *react-native*: Not Found

Library version: 5.1.1
Steps To Reproduce
...
Expected behaviour

I want the video to keep playing when navigating away from the screen (like on iOS)

Reproducible sample code
Video sample
If possible, include a link to the video that has the problem that can be streamed or downloaded from.

Thanks for your answer, I tried it but even with my video component as the root child of the bottom tab bar it still behaves the same way.
I made a reproductible demo code available here : https://github.com/qhoarau/ReactNativeVideoBugDemo
Running this on android : when navigating to another screen, the video stops
Running this on iOS : when navigating to another screen, the video keeps playing (that's what I want)
I don't really know what to do

+1, Currently, I have pass props when next screen to disable play video, maybe that is bad solution
With React navigation V6:
import { useIsFocused } from '@react-navigation/native';
useEffect(() => {
if (!isFocused && !paused) {
setPaused(true);
}
}, [isFocused]);

The problem with this solution, the memory not cleaning when u pause the video programmatically, so careful! Also I'm looking for a solution for this problem

I am also having this issue with expo-av and every camera app. I think that react-navigation is the root problem here (react native screens)

+1, Currently, I have pass props when next screen to disable play video, maybe that is bad solution With React navigation V6: import { useIsFocused } from '@react-navigation/native'; useEffect(() => { if (!isFocused && !paused) { setPaused(true); } }, [isFocused]);

I'm facing the same issue and applied your solution, but still not working

I had to make some work arounds to resolve this... I'v added some listeners to stop the video, like this:
This is to pause when app is in background
useEffect(() => {
    const subscription = AppState.addEventListener('change', nextAppState => {
      if (nextAppState.match(/inactive|background/)) {
        setPaused(true); // something like this
      }
    });

    return () => subscription.remove();
  }, []);

Then to pause on navigation.goBack() method:
useEffect(() => {
    if (!paused && closeRequest) {
      navigation.goBack();
    }
  }, [state.play, closeRequested, navigation]);

  const willLeavePage = useCallback(
    (event: { preventDefault: () => void }) => { // idk how to type this event...
      if (paused) return;

      event.preventDefault(); // it will prevent user to go back and update states
      setPaused(true);
      setCloseRequest(true); // And here is a state to call navigation.goBack() when video is paused
    },
    [state.play]
  );

  useEffect(() => {
    const unsubscribe = navigation.addListener('beforeRemove', willLeavePage);
    return unsubscribe;
  }, [navigation, willLeavePage]);

And last I pause the video when user is sliding the page left-to-right, to close it:
  useEffect(() => {
    const unsubscribe = navigation.addListener('transitionStart', () => { setPause(true); });
    return unsubscribe;
  }, [navigation]);

It's such an ugly code, but it works fine 🤷🏻♂

I solved this problem by giving detachPreviousScreen: false screen option to either all the screens you can navigate to from the screen you are showing the video on, or to the entire navigator created with react-navigation.

Thanks for the solution, it worked for me. 👍

I solved this problem by giving detachPreviousScreen: false screen option to either all the screens you can navigate to from the screen you are showing the video on, or to the entire navigator created with react-navigation.

thanks for the solutions I solved it by
detachInactiveScreens={false}
inside drawer navigator

I solved this problem by giving detachPreviousScreen: false screen option to either all the screens you can navigate to from the screen you are showing the video on, or to the entire navigator created with react-navigation.

This solution works for the stack navigator, but the bottom tab navigator does not have this prop.

This prop is not available in NativeStackNavigator. Any help?

Switching from @react-navigation/native-stack to @react-navigation/stack solved my problem. Thank you for everything.


.NET Core 6

Will this project be ported to .NET Core 6 anytime soon?
Issue: Currently, .NET Core 6 is unsupported.

@voronov-maxim We are heavily use this package, could you took a look at this issue about supporting .net core 6? Thanks!