Update switching-endpoints.md

fixed typo in Azure AD auth example code.

@mrbullwinkle

Can you review this PR?
IMPORTANT: When this content is ready to merge, you must add #sign-off in a comment or the approval may get overlooked.

#label:"aq-pr-triaged"
@MicrosoftDocs/public-repo-pr-review-team

Thanks for the fix!


Add New Prompts

Summary
New prompts are able to be added to the prompt library from within the library
Sub issue of: #4475
Intended Outcome

Add icon exists at the top, on right side of search bar
When clicked, new line item for a prompt is created with two text fields:

Prompt
Tags (positive, negative, style, etc.)

User is able to add  prompt text, weighting, compel functions
Prompt is added once save is clicked

It would be cool if you could click a little + on metadata of previous images to add that prompt to the library, too


Missing records when using headless service

A headless service regarding DNS has some expectations (see Documentation):

For each pod of that service, an A record to the service name is created (this exists already)

“Headless” (without a cluster IP) Services are also assigned a DNS A record for a name of the form my-svc.my-namespace.svc.cluster-domain.example. Unlike normal Services, this resolves to the set of IPs of the pods selected by the Service. [...]

SRV Records are created for named ports (this is missing)

For each named port, the SRV record would have the form _my-port-name._my-port-protocol.my-svc.my-namespace.svc.cluster-domain.example. [...]

Pods have their own A records, if the (headless) service name matches the pod's subdomain  (this is also missing)

If there exists a headless service in the same namespace as the pod and with the same name as the subdomain, the cluster’s KubeDNS Server also returns an A record for the Pod’s fully qualified hostname. For example, given a Pod with the hostname set to busybox-1 and the subdomain set to default-subdomain, and a headless Service named default-subdomain in the same namespace, the pod will see its own FQDN as busybox-1.default-subdomain.my-namespace.svc.cluster-domain.example. DNS serves an A record at that name, pointing to the Pod’s IP. Both pods busybox1 and busybox2 can have their distinct A records

Example:
apiVersion: extensions/v1beta1
kind: Deployment
metadata:
  name: headless-nginx
  namespace: default
spec:
  replicas: 2
  selector:
    matchLabels:
      app: nginx
  template:
    metadata:
      labels:
        app: nginx
    spec:
      subdomain: headless-nginx-service
      containers:
      - image: nginx:1.7.9
        imagePullPolicy: IfNotPresent
        name: nginx
        ports:
        - containerPort: 80
          protocol: TCP
          name: web
---
apiVersion: v1
kind: Service
metadata:
  name: headless-nginx-service
  namespace: default
spec:
  selector:
    app: nginx
  ports:
  - protocol: TCP
    port: 80
    targetPort: 80
    name: web
  clusterIP: None

Result in coredns 1.1.3 (for reference, haven't managed to inject dig into current images)
$ kubectl -n kube-system exec -ti coredns-74cbb9bc68-qbkkt -- dig AXFR cluster.local @localhost | grep headless
_web._tcp.headless-nginx-service.default.svc.cluster.local. 0 IN SRV 0 50 80 headless-nginx-65f9bf7cbd-c2qgp.headless-nginx-service.default.svc.cluster.local.
_web._tcp.headless-nginx-service.default.svc.cluster.local. 0 IN SRV 0 50 80 headless-nginx-65f9bf7cbd-hwnpf.headless-nginx-service.default.svc.cluster.local.
headless-nginx-65f9bf7cbd-hwnpf.headless-nginx-service.default.svc.cluster.local. 0 IN A <IP_ADDRESS>
headless-nginx-65f9bf7cbd-c2qgp.headless-nginx-service.default.svc.cluster.local. 0 IN A <IP_ADDRESS>
headless-nginx-service.default.svc.cluster.local. 0 IN A <IP_ADDRESS>
headless-nginx-service.default.svc.cluster.local. 0 IN A <IP_ADDRESS>

Logs in external-dns:latest
time="2019-08-29T16:01:46Z" level=debug msg="Unable to associate headless-nginx-service headless service with a Cluster IP"
time="2019-08-29T16:01:46Z" level=debug msg="Generating matching endpoint headless-nginx-service.default.cluster.local with HostIP <IP_ADDRESS>"
time="2019-08-29T16:01:46Z" level=debug msg="Generating matching endpoint headless-nginx-service.default.cluster.local with HostIP <IP_ADDRESS>"
time="2019-08-29T16:01:46Z" level=debug msg="Endpoints generated from service: default/headless-nginx-service: [headless-nginx-service.default.cluster.local 0 IN A <IP_ADDRESS>;<IP_ADDRESS> []]"
time="2019-08-29T16:01:46Z" level=debug msg="UPDATE-OLD (ignored): headless-nginx-service.default.cluster.local 300 IN A <IP_ADDRESS> []"
time="2019-08-29T16:01:46Z" level=debug msg="UPDATE-OLD (ignored): headless-nginx-service.default.cluster.local 0 IN TXT \"heritage=external-dns,external-dns/owner=my-external-dns,external-dns/resource=service/default/headless-nginx-service\" []"
time="2019-08-29T16:01:46Z" level=debug msg="UPDATE-NEW: headless-nginx-service.default.cluster.local 0 IN A <IP_ADDRESS>;<IP_ADDRESS> []"
time="2019-08-29T16:01:46Z" level=debug msg="UPDATE-NEW: headless-nginx-service.default.cluster.local 0 IN TXT \"heritage=external-dns,external-dns/owner=my-external-dns,external-dns/resource=service/default/headless-nginx-service\" []"

external-dns arguments:
[...]
      containers:
      - args:
        - --source=service
        - --provider=pdns
        - --pdns-server=https://example.com:8081
        - --pdns-tls-enabled
        - --tls-ca=/dns-1-ca/ca
        - --pdns-api-key=redacted
        - --txt-owner-id=my-external-dns
        - --log-level=debug
        - --interval=30s
        - --domain-filter=cluster.local
        - --fqdn-template={{.Name}}.{{.Namespace}}.cluster.local
        - --ignore-hostname-annotation
        - --publish-internal-services
        - --publish-host-ip
        image: registry.opensource.zalan.do/teapot/external-dns:latest
[...]

Basically the above 4 entries (regarding coredns) are missing in external-dns. careful: the SRV part is also for normal services.
Update: I just found a bug? <IP_ADDRESS> is actually wrong for the headless service...
$ kubectl get endpoints -o wide
NAME                     ENDPOINTS                       AGE
headless-nginx-service   <IP_ADDRESS>:80,<IP_ADDRESS>:80   45m
kubernetes               <IP_ADDRESS>:6443                35d

Actually a better description about the required implementation you can find in the kubernetes dns spec


Modified Signature Error

I've been trying to run version 2.1 of the plugin on grafana 8.4.1 however I keep getting modified signature error.

I'm running everything using docker-compose and then copying the unzipped plugin to the grafana/plugins folder, here's  my docker compose file:
version: '3'
services:
  grafana8:
    image: grafana/grafana:8.4.1
    ports:
      - "3001:3001"
    environment:
      GF_LOG_LEVEL: error
      GF_PLUGINS_ALLOW_LOADING_UNSIGNED_PLUGINS: hadesarchitect-cassandra-datasource
      GF_SERVER_HTTP_PORT: 3001
    volumes:
      - /var/lib/grafana
      - ./dist:/var/lib/grafana/plugins/cassandra

Note that I'm also changing the grafana.ini and adding allow_loading_unsigned_plugins=hadesarchitect-cassandra-datasource afterwards.
I'm also using version 1 of the plugin with grafana 7 and that is working however we've run into some limitations which require grafana 8.

Hi @Snikz18, thanks for letting me know. It's kinda weird because the 2.1.0 release is signed. Let me try it on my own, I'll get back to you soon.
Meanwhile, the new release is to be officially available in the next few days so we will not need manual installation anymore.

Hmmm, wait a second. Where do you get the dist folder? Do you download the source code or the prepared zip image? Please paste the link you used for the download.

I used the zipped folder, didn't rebuild it.
https://github.com/HadesArchitect/GrafanaCassandraDatasource/releases
There's a dist because I just copied your docker-compose and commented and removed what I didn't need, there's no dist folder in my build so it copies nothing.
Sorry for any confusion.

Ah ok I see. So you upload the plugin directly to a docker container?

Hey @Snikz18, sorry, I can't confirm the issue, works well on my side.

Looks like something is wrong with your setup. I'd suggest downloading the file, unzipping it and mounting the hadesarchitect-cassandra-datasource into /var/lib/grafana/plugins/hadesarchitect-cassandra-datasource. Works at my side!

Okay thanks! I'll try again tomorrow. Which is weird it's exactly what I'm doing; just docker cp the unzipped file to that directory.

I might have got a lead on my problem, my grafana container has a permissions issue at startup which I haven't managed to fix yet. Sorry for the issue, i'll close it now.


Complete app crash on cloning private repository

Dev Home version
0.601.297.0
Windows build number
10.0.22621.0
Other software
No response
Steps to reproduce the bug
Log in to an github account with an organisation but don't grant right to it. Then try to clone a private repository from it
Expected result
There are no current expected results except some kind of warning
Actual result
App just completely crashes without any warning.
Included System Information
Os version: 22H2 (0S Build 22621.2715)

Hello,
Thank you for filing this bug.  Any chance you could paste the github URL so I can test with it?

/logs

          Hi @KuroChu . It would be helpful for us if you could share your Dev Home logs.
          These logs can be found at
          `%LOCALAPPDATA%\Packages\Microsoft.Windows.DevHome_8wekyb3d8bbwe\TempState` and
          `%LOCALAPPDATA%\Packages\Microsoft.Windows.DevHomeGitHubExtension_8wekyb3d8bbwe\TempState`.
          You can share these folders via a OneDrive link or zip them and attach them to a
          comment here. If you share this way, you may want to look through the logs in case
          there are any details included that you would like to remove (for example, private
          repo names). Alternatively, you can open a Feedback Hub issue and attach them there.
          If you use Feedback Hub, please paste the URL at the bottom of the report here so we
          can easily find it.

The older version of DevHome and the github extension does have this crash.  Can you please upgrade both DevHome and the github extension to version 0.7?


Insufficient Disk Space for KartaView Downloads

Short Description
I am using version 0.5 of MapSyncer. The script improves with each release. Unfortunately, I haven't been able to successfully download any images.Having entered my download destination, so that MapSyncer knows where to put the downloaded KartaView images, after a short wait, I am then told the size of the KartaView download, and asked whether i'd like to proceed. So far, so good. I have 250gb of local storage available, or up to 500gb of removable storage. The amount I need to download is 2164gb (2tb). The problem is that all the KartaView images have to be downloaded, before they can be uploaded to Mapilio. This means that in order for the transfer to work, I will need to buy an additional 2tb of storage.
Feature Use case
In a similar situation, when Meta/ Facebook acquired Mapillary, many people wanted to move previously captured imagery from Mapillary to KartaView. KartaView had previously been OpenStreetCam, and this seemed like a sensible move. Unfortuantely, KartaView didn't seem to be very open, and didn't care about input from the users/ contributors.
The answer to this, was for someone to write a script that prompted the user to authenticate with Mapillary and KartaView, and then the script would transfer the images, directly. By directly, I mean that nothing was downloaded to the local PC. I mentioned this a long time ago to Mapilio, but MapSyncer has been chosen as the way to import images.
So to recap, my problem is that I need 2tb of space, to download the KartaView images. Looking at Kartaview, I am currently number 69 in the world league table of uploaded images. This means that potentially, lots more people are going to have the same problem as me.
https://photos.google.com/photo/AF1QipNj_UWvgIn_t9KrL34kwq_tyrsUcajgaqWo7WB0
What are the possible solutions?

When the script analyses the images on KartaView, and then says how big the download of images will be, MapSyncer could check the filepath that the user has input, to save the files to, and make sure that enough local storage exists. In my case, it would say "MapSyncer is about to download 2164gb of images, but you only have 500gb of free space; do you wish to (C)ontinue, (S)elect a different location, or (Q)uit?"
Another option would be for me to start the KartaView download, but then escape the process (CTRL+C), when my disk was getting full. The problem with this is that because the script has stopped, it won't go on to upload my images to Mapilio. To make this better, when the script is run, it could check the filepath to see whether any image files already exist, and are ready for upload. If they are, the user could be asked if they would like to proceed with uploading the images. This would also be useful if the KartaView download was interrupted, or for example, in countries where broadband is not so resilient, the link could fail, but be resumed at a later time. If the script checked for existing local images, this could be used as a workaround for very large downloads. This possibly isn't the most elegant solution.
Something slightly more elegant, would be for MapSyncer to assess the KartaView download, and then ask the user which sequences of imagery they would like to download. Image sequences could then be selected (I)ndividually, in (B)atches, or (A)LL. The script could still check locally for sequences and ask if the user wanted to upload them to Mapilio.

Unfortunately, until this situation is addressed, I am not going to be able to transfer my images to Mapilio. I hope this can be sorted/ addressed.
Many thanks,
Chris
chris_debian
Additional
No response

Hi Chris,
MapSyncer is now working much better with the new update. Thank you for your contributions and suggestions.
Update the tool by typing 'pip install --upgrade mapsyncer' into the terminal and resume your uploads.
If you encounter any bugs, please feel free to report them.
Mapilio Team

Hi,
I've tried version 0.7, but it doesn't address this issue. For people that have more KartaView images than local disk space, it seems like they have two options:

Proceed with the download and wait to run out of disk space, or
Halt the process when asked whether to proceed downloading or not.

Please let me know if this is my misunderstanding, because I would like to transfer 2 terrabytes to Mapilio, but right now, I don't think that's possible.
Thanks,
Chris

Hi Chris,
With the last update, we now offer you how many sequences you want to download so that you can download as much as your disk space allows.
If you think you are running out of disk space, we recommend the following approach:

Access the sequence download screen and download sequences according to available disk space.
After the download is complete, you will be directed to the upload step to Mapilio.
After completing the upload process, remove the downloaded sequences from your disk to free up space.

When you return to the sequence download screen, you can continue the download from where you left off without any problems. Rest assured, the system will intelligently prevent re-downloading sequences that have already been uploaded to Mapilio.
We are improving our tool by listening to your suggestions and problems, please let us know the problems or suggestions you have.

Hi, @yusufesatt
Thanks for this. I didn't see this on v0.7 after 30 mins. I'll retry and report the outcome.
Thanks,
Chris

I let the script run overnight, and am pleased to report that a list of sequences was displayed. Sadly, when I tried to download the first three sequences, I got an error to do with 'OSV', which I think was a previous name for Kartaview.

As an aside, how big is each sequence, just wondering how many I can download, before I run out of space?
Thanks,
Chris.

Hi Chris,
Thank you for your feedback.
We fixed the issue as soon as possible, and it will be released in the next update.
Regarding your question about the size of each sequence, we cannot provide a clear answer as Kartaview does not have a specific number of images for sequences. However, we have added this issue to our list for future developments.
Kind regards.

Thanks @yusufesatt . I saw your commit, I'll wait for the new release.
Cheers,
Chris

One step closer with version 0.8. The imagery was downloaded, but I get an error, after logging into Mapilio.

For clarity, I do have a Mapilio account, but log into the app using my OSM details. So that me and others know that they are entering the correct credentials, please could you add a bit more text saying, perhaps 'Not your OSM credentials'. I'm not sure why my the script failed after authentication; could you investigate?
Many thanks,
Chris.
chris_debian

Hi Chris,
Unfortunately, there is no OSM login option at the moment, but it is included in our plans for future updates.
However, if you do not want to upload your data, you can continue the upload process by logging in with a different Mapilio account.

@yusufesatt Hi, thanks for the information. I did use my Mapilio credentials, but thank you for clarifying.
Chris


Driver change

replaced all drivers with a single new implementation, based on go-redis v9
updated travis settings
made it a Go module

example.go file works fine, creates three queues as expected


ActionGroup Icon not provided padding when rendered with sibling and ActionGroup is collapsed

Provide a general summary of the issue here
When an ActionGroup Item renders an Icon and any other sibling (like Text), then the Icon is not provided the needed padding style when in collapsed menu.
CodeSandbox to reproduce
https://codesandbox.io/p/sandbox/wizardly-james-vmfrxg?file=%2Fsrc%2FApp.js%3A13%2C58
🤔 Expected Behavior?

ActionGroup Icon should have equal spacing on both sides
😯 Current Behavior

ActionGroup Icon is pressed against Chevron
💁 Possible Solution
The issue appears to be caused by the pseudo-class :only-child used as part of the selector that applies the expected padding.  The selector looks like this:
.spectrum-ActionButton .spectrum-Icon:only-child {
    padding-inline-end: var(--spectrum-actionbutton-icon-padding-x, var(--spectrum-global-dimension-size-85))
}

The problem is if you render the icon with a  label, the label is still present in the DOM as a sibling to the Icon and is only hidden with CSS styles.
<ActionGroup maxWidth={100}>
  <Item key="list">
    <ViewList />
    <Text>Table View</Text>
  </Item>
</ActionGroup>

🔦 Context
No response
🖥 Steps to Reproduce
https://codesandbox.io/p/sandbox/wizardly-james-vmfrxg?file=%2Fsrc%2FApp.js%3A13%2C58
Version
3.33.1
What browsers are you seeing the problem on?
Chrome
If other, please specify.
No response
What operating system are you using?
Windows 11
🧢 Your Company/Team
Adobe / Assets Essentials
🕷 Tracking Issue
No response

Thanks for the issue, please make sure the Codesandbox is public.
Otherwise, it looks like it's behaving correctly to me in our testing storybook https://reactspectrum.blob.core.windows.net/reactspectrum/88c7f4ee5f959b6c3d0b5b1f877d3e63b6c88aca/storybook/index.html?path=/story/actiongroup--summary-icon&args=overflowMode:collapse;buttonLabelBehavior:collapse&providerSwitcher-express=false
Will need to see the codesandbox to know if I'm missing something

@snowystinger Sorry about that, the Codesandbox is now public.
You can see the visual padding issue on the main documentation site as well - https://react-spectrum.adobe.com/react-spectrum/ActionGroup.html#single-selection, check the icon padding in the Single Selection example using the TextAlign icons.

Yep, I can see it now in the docs. Thanks for bringing it up.
Interestingly, it is working here https://reactspectrum.blob.core.windows.net/reactspectrum/88c7f4ee5f959b6c3d0b5b1f877d3e63b6c88aca/storybook/index.html?path=/story/actiongroup--summary-icon&args=overflowMode:collapse;buttonLabelBehavior:hide;selectionMode:single&providerSwitcher-express=false
It looks like the problem line is here https://github.com/adobe/react-spectrum/blob/8577c4d8bed1f37db3c840f230e844fd877d084a/packages/%40adobe/spectrum-css-temp/components/button/index.css#L230
We can probably use some more classes/state to determine that we should indeed have padding-inline-end


Python API document not accurate

Package Name:  msrestazure
Package Version:
Operating System:
Python Version:

Describe the bug
Python API ref document has typo and is not clear on measurement unit.
To Reproduce
Steps to reproduce the behavior:

Go to https://learn.microsoft.com/en-us/python/api/msrestazure/msrestazure.azure_operation.azureoperationpoller?view=azure-python#msrestazure-azure-operation-azureoperationpoller-wait
Notice the description of 'timeout' parameter. It says: "Perion of time to wait for the long running operation to complete."

Expected behavior
Feedback from the doc page asked in what units is the parameter used. There also seems to be a typo ("Period" instead of "Perion")
Screenshots
If applicable, add screenshots to help explain your problem.
Additional context
Add any other context about the problem here.

Label prediction was below confidence level 0.6 for Model:ServiceLabels: 'Docs:0.48914772,Authorization:0.028001916,Machine Learning:0.01625524'

This code was used by our code generator alpha, and is no longer maintained nor used by any running code for at least 5 years. Given that, we don't plan to update the documentation as no customers can access this method anymore (no SDK will return this type anymore).


Vorticity to velocity

Hello, thank you for you work. I have a misunderstanding with the obtaining velocity (for Navier Stokes equation) from given vorticity part. We actually need it for loss and you just wrote in the paper that it is easy, can you explain in more detail? If I understand correctly, that means we have to construct the inverse operator for curl, am I right? But it is not too easy 😅, or I something missed?

For the 2d periodic Navier-Stokes equation, the velocity can be computed by first getting the stream function. The velocity is the derivative of the stream function (https://github.com/neuraloperator/physics_informed/blob/8246da4e527e601abb0f35a25fbae515eff46570/train_utils/losses.py#L87).
In general, for non-periodic case (like the cavity flow), it's non-trivial to get the velocity from vorticity. In this case we will the velocity-pressure formulation. (https://github.com/neuraloperator/physics_informed/blob/8246da4e527e601abb0f35a25fbae515eff46570/cavity_flow.py#L249)


Feature request: A "password" field with option to hide and show password input

🚀 Feature request
A "password" field with option to hide and show password input
Motivation
In a sign in form, a password field is often in need. By default, password is always hidden as little black dots and it would be nice if we could have an option to see the exact input (for example with a little eye icon)
Example
Here is an example from antd
The form looks like this

By default when a password is entered, it is hidden

If we click on the little eye icon on the right, the password is revealed

Possible implementations
On sign in pages

wouldn't mind working on this one

This seems too specific to be a component. Maybe just an example would be enough?

Instead of just password, the option to add a component at the start and end of an input would be good. Seems to common in other ui frameworks.

I think this is closed by #753?


Admin | Sync Template v3 (Flows): The response is not in a JSON format.

Describe the bug
First runs of the Admin | Sync Template v3 (Flows) Flow results in error:
{
  "error": {
    "code": 404,
    "source": "unitedstates-002.azure-apim.net",
    "clientRequestId": "fbc0b4ac-8a2e-4f1f-9d93-b1acddb250f5",
    "message": "The response is not in a JSON format.",
    "innerError": "Cannot read server response."
  }
}

Component (please tell us which flow or app you are experiencing issues with):

Solution: Core
Version: 2.0.10
App or Flow: Flow

To Reproduce
Steps to reproduce the behavior:

Ensure the Sync Template flows are already turned on for the following object types:
Apps, Connectors, Custom Connectors, Flows, Model Driven Apps, PVA, RPA
Turn on Admin | Sync Template v3. When it completes, turn it back off.

Expected behavior
Flow would run as expected
Screenshots

Additional context
Add any other context about the problem here.

Hello. This is a known product bug and the product team has half the fix rolled and is working on the other half.
Tracked by #941


Add pipeline step for uploading to Codecov

Codecov may be a better and simpler solution than Azure Artifacts for displaying coverage status. Test out the integration here to see if we can successfully upload reports to Codecov.

Codecov Report

:exclamation: No coverage uploaded for pull request base (main@f146d52). Click here to learn what that means.
The diff coverage is n/a.

@@          Coverage Diff           @@
##             main     #11   +/-   ##
======================================
  Coverage        ?   0.00%
======================================
  Files           ?      15
  Lines           ?     157
  Branches        ?       0
======================================
  Hits            ?       0
  Misses          ?     157
  Partials        ?       0

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 f146d52...cfb7580. Read the comment docs.


⚠ Secret Website 3 has degraded performance

In 8b02b85, Secret Website 3 ($SECRET_WEBSITE_3) experienced degraded performance:

HTTP code: 200
Response time: 2618 ms

Resolved: Secret Website 3 performance has improved in 75c5a0b.


First pass at implementing simple two-qubit RB with atomic Cliffords.…

We could probably shorten the name...

A minor gripe, but this is simultaneous RB, not 2Q RB, no?

That's right.  I had originally written code in the pull request specifically for the two qubit case.  @caryan encouraged me to make it more general.

I'm fixed some of the obvious typos and relabeled seqs in the doc string.  Is that what you were referring to Colm?

It would also be good to fix the commit message.

It needs to be fixed in many of the docstrings but with the Bokeh plotting we no longer return the plot handle.

@caryan it seems none of the basic sequences return anything.  I won't convolute the commits, but is this something we should fix for all the basic sequences?  Also, hat tip for the zip(*seqs) syntax!
The list compression here is not readable at all if you ask me.  I'll have to see what I can do to make these more readable in the morning.


store .primsa in a directory and make models extensible and variable for different databases

Problem

currently schema.prisma merges generator, datasource, model together within a file, which makes it hard for debugging and extending.
Suggested solution

I propose that schema.prisma can be both a file and a directory, where we can extend a lot of things inside the directory.
It can be like this:
.
├── datasource
│   ├── mongodb.ds
│   ├── mysql.ds
│   └── oracle.ds
├── generator
│   ├── mongodb.gen
│   ├── mysql.gen
│   └── oracle.gen
└── model
    ├── base.model
    └── ext
        ├── mongodb.model
        ├── mysql.model
        ├── oracle.model
        ├── postgre.model
        ├── sqlite.model
        └── sqlserver.model

Alternatives

Additional context

Hi,
Thanks for reporting this! It has already been reported before, so I am going to close this as a duplicate of https://github.com/prisma/prisma/issues/2377


feat(vue-query): devtools options to set offline mode, forced loading and error states

Codecov Report
Patch and project coverage have no change.

Comparison is base (ae6c6a3) 88.90% compared to head (80c09c4) 88.90%.

:mega: This organization is not using Codecov’s GitHub App Integration. We recommend you install it so Codecov can continue to function properly for your repositories. Learn more
Additional details and impacted files
@@           Coverage Diff           @@
##            alpha    #5164   +/-   ##
=======================================
  Coverage   88.90%   88.90%
=======================================
  Files          78       78
  Lines        2911     2911
  Branches      829      829
=======================================
  Hits         2588     2588
  Misses        275      275
  Partials       48       48

Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Do you have feedback about the report comment? Let us know in this issue.


mitmproxy 8.1.1 is identified as malware by McAfee and other AV vendors

Please update the hash so it will not be detected as a malware by multiple Anti-Virus vendors as McAfee.
Detection screenshot
Discussed in https://github.com/mitmproxy/mitmproxy/discussions/5467

Originally posted by CruzMarcio July 19, 2022
McAfee Endpoint Security identifies mitmproxy.exe as malware:
Adaptive Threat Protection repaired C:\tools\mitmproxy\mitmweb.exe TargetType, because its reputation (Known Malicious) is below the configured Clean threshold.
Analyzer / Detector
Product name | McAfee Endpoint Security
Product version | <IP_ADDRESS>83
Feature name | Real Protect Cloud

Threat
Action taken | Clean
Threat category | Malware Detected
Threat event ID | 35107
Threat handled | Yes
Threat name | Real Protect-peft7!4CF8F35B22D3
Threat severity | Critical
Threat timestamp | 7/19/2022 9:08 AM
Threat type | Trojan

Target
Target hash | 4cf8f35b22d371a1bebfa4bf4c5b03ee
Target name | mitmweb.exe

I have already replied in the discussion you linked. There's no need to open a new issue.


Add support to equal sign - '=' - on URL

Updated filename regex pattern to allow the equal sign as being part of the filename portion of the route, otherwise it would fall on 404 error.

Can you elaborate, when this error occurs?

Sure.
In this case I was using a base64 encoded string as filename (which sometimes ends with an equal sign).
I realized that when the equal sign is present on URL, the route is not recognized.
I'm using intervention/imagecache for this but the route is created in this package (intervention/image) service provider.
To clarify, for instance:
Let's take 'images/cache' as the imagecache route.
If I try to get images/cache/module_desk/uploads/module_avatar/KEQbRnXa47uqIFaEoUutsD98lqc5Rv-metaQmFubmVyLW1vYmlsZS5qcGc=-.jpg it doesn't work, because it fails the regex, so the route is not even called.


Error migrating manufacturer

make migrate fails after merge of #716
Trace after "migration to company object requires user input" and so on.
Python 3.8.2
Traceback (most recent call last):
  File "manage.py", line 22, in <module>
    execute_from_command_line(sys.argv)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/core/management/__init__.py", line 381, in execute_from_command_line
    utility.execute()
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/core/management/__init__.py", line 375, in execute
    self.fetch_command(subcommand).run_from_argv(self.argv)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/core/management/base.py", line 323, in run_from_argv
    self.execute(*args, **cmd_options)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/core/management/base.py", line 364, in execute
    output = self.handle(*args, **options)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/core/management/base.py", line 83, in wrapped
    res = handle_func(*args, **kwargs)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/core/management/commands/migrate.py", line 232, in handle
    post_migrate_state = executor.migrate(
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/db/migrations/executor.py", line 117, in migrate
    state = self._migrate_all_forwards(state, plan, full_plan, fake=fake, fake_initial=fake_initial)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/db/migrations/executor.py", line 147, in _migrate_all_forwards
    state = self.apply_migration(state, migration, fake=fake, fake_initial=fake_initial)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/db/migrations/executor.py", line 245, in apply_migration
    state = migration.apply(state, schema_editor)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/db/migrations/migration.py", line 124, in apply
    operation.database_forwards(self.app_label, schema_editor, old_state, project_state)
  File "/home/chschlue/.local/lib/python3.8/site-packages/django/db/migrations/operations/special.py", line 190, in database_forwards
    self.code(from_state.apps, schema_editor)
  File "/home/chschlue/inventree/InvenTree/company/migrations/0019_auto_20200413_0642.py", line 262, in associate_manufacturers
    map_part_to_manufacturer(part, idx, part_count)
  File "/home/chschlue/inventree/InvenTree/company/migrations/0019_auto_20200413_0642.py", line 143, in map_part_to_manufacturer
    name = str(part.manufacturer_name)
AttributeError: 'SupplierPart' object has no attribute 'manufacturer_name'
make: *** [Makefile:15: migrate] Error 1

@chschlue oops, I've worked out what's going on. I had a test database which I was using for the migrations but this fell through the cracks. I didn't know that this particular error could happen, but it makes a lot of sense in hindsight. Learned something new!

Please pull down and try again. Hopefully this has fixed the issue for you.
If it does work, please let me know how the manual remapping of manufacturers goes for you.

Actually please wait for a little bit, there might be another bug now... :|

Too late...

Seems to be working at first glance.

Select an option from the list below:
0) - Create new manufacturer 'Finder'

1) - Use manufacturer 'Infineon'

Ok, wait for https://github.com/inventree/InvenTree/pull/720 to be merged before you run, otherwise the migration will "work" but the data won' be saved properly!
If you're midway through the migration just press "Ctrl-C" to cancel it.

It uses fuzzy match to try and "guess" which manufacturer you might mean. The match threshold is set pretty low so there may be some spurious matches.

Suppose I already finished migration and ran. What then? :)

Give me a few minutes ;)

Just asking, it's not a production system so I don't actually lose much.

Hypothetically the migration should have a "rollback" feature which performs the opposite operation. However I just found a separate bug in that. I need to fix it anyway, so I'll push something soon.

Ok, after grabbing latest commit, you have two options:

Revert to a backup point on the database and simply run make migrate. The migrations should apply properly now.

Run the following sequence (not guaranteed if the initial migration has mucked up the data)

cd InvenTree
python manage.py migrate company 0017
python manage.py migrate

Please let me know how you go in either case.

Should I wait a bit to update? Can I get an 'ALL OKAY' when its good? I guess I will be doubly sure to do a backup before update this time.

@a7hybnj2 what sort of database are you running? sqlite? mysql?
I am pretty sure the migration is working correctly now, but I'd recommend a database backup before updating, just to be sure.

Reverse migration worked.
How is DB restore supposed to be done, BTW? I only used "backup" before, hoping for "restore" to be implemented by the time I need it ;)

The "restore" functionality needs some work, I fear it depends on the particular database installation. Currently it is "left to the user" to manage sensible backup strategies...
In the long term I'd like to integrate a simpler and "safer" solution...

😬 I have been zfs snap shot-ting my whole InvenTree jail in the event I need to roll back.


feat(searchbar): add cancel button options

Pull request checklist
Please check if your PR fulfills the following requirements:

[x] Tests for the changes have been added (for bug fixes / features)
[x] Docs have been reviewed and added / updated if needed (for bug fixes / features)
[x] Build (npm run build) was run locally and any changes were pushed
[x] Lint (npm run lint) has passed locally and any fixes were made for failures

Pull request type

Please check the type of change your PR introduces:

[ ] Bugfix
[x] Feature
[ ] Code style update (formatting, renaming)
[ ] Refactoring (no functional changes, no api changes)
[ ] Build related changes
[ ] Documentation content changes
[ ] Other (please describe):

What is the current behavior?

Issue Number: https://github.com/ionic-team/ionic/issues/18399
What is the new behavior?

Adds always, never, and focus options for show-cancel-button
Deprecates  the true and false options

Does this introduce a breaking change?

[ ] Yes
[x] No

Other information

Original PR: https://github.com/ionic-team/ionic/pull/18401

Looks great, nice work!


center the padding in evaluation preprocessing

As i mentioned in the issue #921 the padding during the evaluation process is not centered but the image is putted in the upper left corner. I suppose that this is a bug so i opened this pull request to propose a fix to this very simple issue.

 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.Simone Luetto seems not to be a GitHub user. You need a GitHub account to be able to sign the CLA. If you have already a GitHub account, please add the email address used for this commit to your account.You have signed the CLA already but the status is still pending? Let us recheck it.

@simoneluetto  YOLOX does not apply center padding during training. So it's better not center padding during inference. WDYT?

@FateScript I thought that using mosaic data augmentation the single images where not padded at all, my fault. Anyway sorry to bother but there is a reason for the choice of padding only on two sides of the image?

is a reason for the choice of padding only on two sides of the image?

Padding method usually doesn't matter for detection task. Applying top-left side padding has no side effect on box annotations,  so we choose it.


Test Cases pass incorrect parameters with a space in the parameters section of the attribute

Not able to test in Tokyo yet, but in Berlin when I use a test case something like this
    [Test]
    //DUnitX/Delphi BUG?   Shows expected as "True", should be "False".
    //  Space seems to freak it out
    [TestCase('TestTop_NoChg2', '3,0, False')]
    [TestCase('TestTop_NoChg3', '3,0,False')]
    procedure Change_XX_Sets_DirtyFlag(WhichItem: Integer; Incr: Integer; ExpectedFlag: boolean);

TestTop_NoChg3 works fine and False is passed correctly to "ExpectedFlag"
In TestTop_NoChg2 the test fails because ExpectedFlag gets set to True.
I have traced in to the DUnitX code in the debugger, and it looks like in
DUnitX.Attributes.pas
constructor TestCaseAttribute.Create()...
..

  lValues := SplitString(AValues,ASeparator);
  l := Length(lValues);
  SetLength(FCaseInfo.Values,l);

..

returns
['3,'0,' False']
Then
TValue.From(' False')  returns true
Now I know this is an issue I can work around it, but it does seem like rather a weakness. It is rather hard to debug unless you know to look for it and could lead to false positives, or worse still "false negatives" on tests, letting them pass when they really need to fail.
Thanks

@DaveMartel I have come across this issue with 10.2 Tokyo.
[testcase('foo','12, 13')]
procedure myTest(const aExpected: integer; const aInput: integer);

aInput will actually equal 13 as an integer.  However
[testcase('bar','12, input')]
procedure myOtherTest(const aExpected: integer; const aInput: string);

This time aInput equals ' input' instead of 'input'.
I wouldn't call this a huge deal now that I have come across it.  As long as there is now space following the , there is no problem.
Would it be acceptable to trim all spaces that follow the character that separates values?
I think this is allowed:
[testcase('my test','12, 13',', ')]

The last part designates the separation string.  I am not sure if more than one character is allowed.  I have not used it before, just opting for the default ,.

Again using Berlin, rather than Tokyo... but I suspect the version is not the issue....
I have tried using a multi character separator, but it does not work. Looking in the DUnitX source it would appear to use the separator you suggest as 2 possible separators, comma and space. Hence it would split strings. So no go.
I agree it is not the biggest issue. I just thought I would raise it since I saw it.
The biggest issue for me was the fact that nothing fails and nothing is flagged, you just get an unexpected result. Since unexpected results are the sort of thing we use unit testing to avoid, it seems to me that it might be something that would merit fixing.

When using the parameters in the tests, always always always use Trim() unless spaces are meaningful in your design.
This will save you lots of trouble.
Although it is a bit inconvenient the way DUnitX handles it, I wouldn't consider it huge problem. But it would be good to handle the spaces

The problem with us trimming spaces, is what then happens if you actually want to pass spaces? At the moment the code that fills the params is pretty looseygoosey (in TDUnitXTestCase.Create ) and doesn't really do anything to ensure correct types etc. I'm happy to look at suggests, feel free to submit a pull request, unfortunately I don't have time to look at this right now, working 7 days a week dealing with existing workload (ie paying the bills)!

@vincentparrett Exactly and that's why I said unless spaces are meaningful in the design.
My suggestion was to the user to use trim in the procedure as they see fit. In my view, nothing has to change regarding the spaces as they can be managed in the code as already said. So I don't thing this is a real issue.
Alternatively, and if this is a needed functionality, we could have a kind of global option (like opIgnoreSpaces = false) which can be changed whenever needed. Or, even a third parameter in the TestCase attribute to specify this behaviour.
Having said that I think it's better all of us to work on some overload attributes to accept other types than string.

My original post was not say it was right or wrong. I said in my post that it was something you can work around (and yes, using trim is what I was thinking).
I really only raised it so people were aware of it. It is not mentioned anywhere I have found. I googled around and found no other reports of this. So I hoped by pointing out the issue that perhaps people might mot get caught out.
So an option might be nice, but just happy if it adds a little to the global knowledge.

Add one more optional argument 'ATrimSpaces: Boolean = False' to DUnitX.Attributes.TestCaseAttribute.Create and all will be correct and predictable.


[BUG] CSI failed to recover FUSE mount point for AlluxioRuntime

What is your environment(Kubernetes version, Fluid version, etc.)
Describe the bug
FUSE Recovery failed when using AlluxioRuntime.
What you expect to happen:
Alluxio FUSE should be successfully recovered after deleting the FUSE pod.
How to reproduce it
Simply run the e2e script in #2477 can reproduce this bug.
Additional Information

The bug is probably caused by an incorrect order among Pod Readiness, FUSE mount point readiness and CSI Plugin's recover() func logic.
Currently, CSI plugin recovers broken mount points only if it detects any FUSE container restarts and become ready. However, it is possible that the execution order goes like:

Alluxio FUSE Pod restarts
Alluxio FUSE Pod ready
CSI detects container restart and recovers broken mount points (At this time, Alluxio FUSE mount point is not ready, so nothing happened)
Alluxio FUSE mount point ready
CSI Plugin won't retry Step 1 to 4 because it detects no container restarts

The bug is probably caused by an incorrect order among Pod Readiness, FUSE mount point readiness and CSI Plugin's recover() func logic.
Currently, CSI plugin recovers broken mount points only if it detects any FUSE container restarts and become ready. However, it is possible that the execution order goes like:

Alluxio FUSE Pod restarts
Alluxio FUSE Pod ready
CSI detects container restart and recovers broken mount points (At this time, Alluxio FUSE mount point is not ready, so nothing happened)
Alluxio FUSE mount point ready
CSI Plugin won't retry Step 1 to 4 because it detects no container restarts

Can scanning /proc/self/mountinfo solve this issue?


Adding Windows support

Description of changes

Introduce new options log-file-dir (for Windows specific workflow) and proxy-variable
Decouple debug logging for Windows and other platforms. Make Windows logging write to file with seelog
Update version of containerd to 1.5.0 in go.mod

Why these changes

Introduce log-file-dir option for allowing Windows users to determine the directory the debug logs will be sent. Since Windows shim logger's logs will be written to a file this option will be only supported on Windows. If it is not provided then will default to C:\ProgramData\Amazon\ECS\shim
journald logging is not supported on Windows, so seelog was chosen as the alternative for Windows.
Binary logging support for Windows is not supported in containerd version 1.3.0.

Testing

make lint and make test
Ran shim logger on a Windows EC2 instance with containerd running with log-file-dir and proxy-variable options set.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

All the changes are tested with make lint and make test

Tested code with make lint and make test


try self.interpreter!.invoke() App got crashed on this line

Swift 5

        try self.interpreter!.copy(inputData, toInputAt: 0)
        try self.interpreter!.invoke() // App got crashed on this line without any log(Thread 1: EXC_BAD_ACCESS (code=1, address=0x32e110180))

Even Tensor were allocated still getting crash.

@ShiviAGL,
Could you please provide the complete standalone code & the tensorflow version you are using and helps us to analyse the issue in an effective way. Thank you!

Hi TilakRayl
Thanks for reply :
Version is not mention only used  pod 'TensorFlowLiteSwift'
//TFLITE Model parameter example
let batchSize = 1
let inputChannels = 3
let inputWidth = 640
let inputHeight = 640

private var inputTensor: Tensor?
private var outputTensor: Tensor?

func checkTfliteImage (imageTocheck : UIImage) -> (Bool){

    let myimage: UIImage = imageTocheck.resized(to: CGSizeMake(CGFloat(inputWidth), CGFloat(inputHeight)))

    let image : CGImage = myimage.cgImage!

    guard let context = CGContext(
      data: nil,
      width: image.width, height: image.height,
      bitsPerComponent: 8, bytesPerRow: image.width * 4,
      space: CGColorSpaceCreateDeviceRGB(),
      bitmapInfo: CGImageAlphaInfo.noneSkipFirst.rawValue
    ) else {
      return false
    }

    context.draw(image, in: CGRect(x: 0, y: 0, width: image.width, height: image.height))
    guard let imageData = context.data else { return false }

    var inputData = Data()
    for row in 0 ..< inputWidth {
      for col in 0 ..< inputHeight {
        let offset = 4 * (col * context.width + row)
        // (Ignore offset 0, the unused alpha channel)
        var red = imageData.load(fromByteOffset: offset+1, as: UInt8.self)
        var green = imageData.load(fromByteOffset: offset+2, as: UInt8.self)
        var blue = imageData.load(fromByteOffset: offset+3, as: UInt8.self)

        inputData.append(&red, count: 1)
        inputData.append(&green, count: 1)
        inputData.append(&blue, count: 1)
      }
    }
    do {
        try self.interpreter!.copy(inputData, toInputAt: 0)
        try self.interpreter!.invoke()
        var output = try interpreter!.output(at: 0)
        let boundingBoxes =
            UnsafeMutableBufferPointer<Float32>.allocate(capacity: 4 * 40)
        output.data.copyBytes(to: boundingBoxes)

        output = try interpreter!.output(at: 1)
        let labels =
            UnsafeMutableBufferPointer<Float32>.allocate(capacity: 40)
        output.data.copyBytes(to: labels)

        output = try interpreter!.output(at: 2)
        let probabilities =
            UnsafeMutableBufferPointer<Float32>.allocate(capacity: 40)
        output.data.copyBytes(to: probabilities)

        guard let labelPath = Bundle.main.path(
            forResource: "labels",
            ofType: "txt"
        ) else { return true }
        let fileContents = try? String(contentsOfFile: labelPath)
        guard let labelText = fileContents?.components(separatedBy: "\n") else { return true }

        for i in 0 ..< 40 {
            let top = boundingBoxes[0 * i]
            let left = boundingBoxes[1 * i]
            let bottom = boundingBoxes[2 * i]
            let right = boundingBoxes[3 * i]

            let labelIdx = Int(labels[i])
            let label = labelText[labelIdx]
            let confidence = probabilities[i]

            if confidence > 0.66 {
                print("Object found: \(label) (confidence: \(confidence))")
                print("  Top-left: (\(left),\(top))")
                print("  Bottom-right: (\(right),\(bottom))")
            }
        }

        try self.interpreter!.allocateTensors()
    } catch {
        print("error in recognition \(error.localizedDescription)")
        //error in recognition Provided data count 150528 must match the required count 1228800.

    }
    return false
}

Hi @ShiviAGL
Could you please share TFLite model if possible to analyse and better understand the issue?
Thanks.

hi pjpratik ,
can you plz chk .tflite file with attached url below :
https://drive.google.com/file/d/1bYRxc1YLwhcr5KsnM2l_hPe0RfIEeP_A/view?usp=drive_link
please let us know how to preprocess the input image for this file as tensor input. and what will be the values of:

tflite_metadata.json
The model's input dimensions
The model's maximum detections
dict.txt or labels.txt file to get the name of detected object

Hi @ShiviAGL

tflite_metadata.json

We can use MetaDatadisplayer which is available through tflite_support library.
get_metadata_json() can be used which converts the metadata into a json string.

The model's input dimensions

I did observe that model's input dimensions are [1,320,320,3].

The model's maximum detections

And the model has maximum detections of 10.

dict.txt or labels.txt file to get the name of detected object

We can get the label map from the tflite model with metadata by unzipping it.
Please find this gist for the same.
Thanks.

hi pjpratik ,
Thanks for your reply ,
can you please help us to understand how an image can be passed as tensor input with dimensions [1,320,320,3],  for this model.

Hi @ShiviAGL ,
Since you have a model with metadata, you can use TensorFlow Lite Task Library with the same tflite_support library which provides easy to use interfaces for TFLite.
Incase if you are interested in Swift based implementation, please check this model data handler in object detection example.
Please let us know if it helps.
Thanks.

ok , thanks .
will check and let you know.

hi @pjpratik ,
I have used TensorFlowLiteTaskVision and followed the steps using https://www.tensorflow.org/lite/inference_with_metadata/task_library/object_detector#swift
    guard let modelPath = Bundle.main.path(forResource: "ssd_320_fpnlite_rtpd_exterior_fp32_metadata",
                                                ofType: "tflite") else { return }

    let options = ObjectDetectorOptions(modelPath: modelPath)

    // options.classificationOptions.maxResults = 3

    do {
        let detector = try ObjectDetector.detector(options: options)

        guard let image = UIImage (named: "carimage.jpeg"), let mlImage = MLImage(image: image) else { return }

        do{ let detectionResult = try detector.detect(mlImage: mlImage)}
        catch {throw error}

    }
    catch{
        throw error
    }

then I am getting this errors in log:
2023-08-10 17:26:39.458625+0530 Nexa[5290:4005447] [tcp] tcp_input [C<IP_ADDRESS>:3] flags=[R.] seq=3641772054, ack=340852762, win=0 state=CLOSED rcv_nxt=3641772007, snd_una=340852685
2023-08-10 17:26:39.473151+0530 Nexa[5290:4003754] Initialized TensorFlow Lite runtime.
INFO: Initialized TensorFlow Lite runtime.
2023-08-10 17:26:39.477445+0530 Nexa[5290:4003754] Created TensorFlow Lite XNNPACK delegate for CPU.
INFO: Created TensorFlow Lite XNNPACK delegate for CPU.
2023-08-10 17:26:39.481691+0530 Nexa[5290:4003754] failed to create XNNPACK runtime
ERROR: failed to create XNNPACK runtime
2023-08-10 17:26:39.482903+0530 Nexa[5290:4003754] failed to create XNNPACK runtime
ERROR: failed to create XNNPACK runtime
2023-08-10 17:26:39.483089+0530 Nexa[5290:4003754] failed to create XNNPACK runtime
ERROR: failed to create XNNPACK runtime
2023-08-10 17:26:39.483877+0530 Nexa[5290:4003754] Node number 157 (TfLiteXNNPackDelegate) failed to prepare.
ERROR: Node number 157 (TfLiteXNNPackDelegate) failed to prepare.
2023-08-10 17:26:39.484266+0530 Nexa[5290:4003754] Restored original execution plan after delegate application failure.
ERROR: Restored original execution plan after delegate application failure.
2023-08-10 17:26:59.219212+0530 Nexa[5290:4005310] [tcp] tcp_input [C<IP_ADDRESS>:3] flags=[R.] seq=51485920, ack=3936341466, win=0 state=LAST_ACK rcv_nxt=51485920, snd_una=3936341420
2023-08-10 17:26:59.219761+0530 Nexa[5290:4005310] [tcp] tcp_input [C<IP_ADDRESS>:3] flags=[R.] seq=3431658725, ack=3245991258, win=0 state=LAST_ACK rcv_nxt=3431658725, snd_una=3245991212
2023-08-10 17:26:59.224111+0530 Nexa[5290:4005310] [tcp] tcp_input [C<IP_ADDRESS>:3] flags=[R.] seq=51485920, ack=3936341498, win=0 state=CLOSED rcv_nxt=51485920, snd_una=3936341420
Please have a look and help me to understand what can we do to get result by passing image for this model?

Hi @ShiviAGL
I have tried your model with Python API with random data and was able to get results. Please find this gist.
There seems to be no issue model. Could you check this ios object detector example which uses the TFLiteTaskLibrary and let us know if it helps?
Thanks.

Hi @pjpratik
Thanks for your reply .
We have tried the same model with Android studio as well and its working fine but for iOS Xcode with swift 5 we are unable to get results from this model so we are just looking for the help to integrate this model in our iOS project.
I have tried with
pod 'TensorFlowLiteSwift'
and
pod 'TensorFlowLiteTaskVision'
with different ways with frames and images as well as an tensor input but with all the different ways i got errors :
error in recognition Provided data count 150528 must match the required count 1228800
and then after checking the input interpreter.invoke() failed and then followed the TensorFlowLiteTaskVision and then again for the simple image getting error : failed to create XNNPACK runtime
also tried with  Firebase as well (https://firebase.google.com/docs/ml-kit/ios/use-custom-models)
So the requirement is to detect the image(not frame) with this model in ios swift 5
and for that what will be the correct approach as I have checked TFLiteTaskLibrary too and here we can use TensorFlowLiteTaskVision and then I have implemented the same but again failed with XNNPACK runtime issue.
so can you please help us to understand what are the reasons to got these errors.
Is there any complete guide to understand how an image can be used for object detection using Tflite models with detailed description for the tensor input dimensions and how can we use the values like maximum number of detections and image with dimension [1,320,320,3] and the  input preprocessing mean , input preprocessing standard deviation with datatype float32.

Hi @ShiviAGL
Thanks for the information. Seems like the issue is with iOS only, as per understanding.
@pkgoogle Could you please look into this issue?
Thanks.

Hi @ShiviAGL, I was able to get a result from your model with my toy project that's basically just this:
_1441_toyApp:
//
//  _1441_toyApp.swift
//  61441_toy
//
//

import SwiftUI
import TensorFlowLiteTaskVision

@main
struct _1441_toyApp: App {
  init() {
    // Initialization
    do {
      guard let modelPath = Bundle.main.path(forResource: "ssd_320_fpnlite_rtpd_exterior_fp32_metadata",
                                             ofType: "tflite") else { return }

      let options = ObjectDetectorOptions(modelPath: modelPath)

      // Configure any additional options:
      // options.classificationOptions.maxResults = 3

      let detector = try ObjectDetector.detector(options: options)

      // Convert the input image to MLImage.
      // There are other sources for MLImage. For more details, please see:
      // https://developers.google.com/ml-kit/reference/ios/mlimage/api/reference/Classes/GMLImage
      guard let image = UIImage (named: "istockphoto-925066016-612x612.jpg"), let mlImage = MLImage(image: image) else { return }

      // Run inference
      let detectionResult = try detector.detect(mlImage: mlImage)
      print(detectionResult)
    } catch {
      print(error)
    }
  }

    var body: some Scene {
        WindowGroup {
            ContentView()
        }
    }
}

ContentView (Default app one):
//
//  ContentView.swift
//  61441_toy
//
//

import SwiftUI

struct ContentView: View {
    var body: some View {
        VStack {
            Image(systemName: "globe")
                .imageScale(.large)
                .foregroundColor(.accentColor)
            Text("Hello, world!")
        }
        .padding()
    }
}

struct ContentView_Previews: PreviewProvider {
    static var previews: some View {
        ContentView()
    }
}

my PodFile:
# Uncomment the next line to define a global platform for your project
# platform :ios, '9.0'

target '61441_toy' do
  # Comment the next line if you don't want to use dynamic frameworks
  # use_frameworks!

  # Pods for 61441_toy
  pod 'TensorFlowLiteTaskVision'

end

My image is different, but I didn't try anything special with it. My swift version is also 5. Can you try with a very simple project like the above and see if you can get a result? Thanks for your help.

@pkgoogle
Thanks for your reply, will check this approach too and let you know about the results.


Create git tag on release

I'm pretty forgetful so I doubt I'd remember to do this

Coverage remained the same at 93.475% when pulling d81f736b34ae6907fcfd70a802ad1590fcc71e18 on JackDanger:create-git-tag-on-release into 8e57dc92f405daa350b8b901cf13181883c65814 on spulec:master.


Drag events do not fire in edit mode

I'm using the 1.0rc3 code in master, and I've set a polygons to always be in edit mode. draw:dragend and draw:drawstop are not firing at all though. Note also that I've hidden the edit button as my polygons are always in edit mode but even when i use the edit button, the polygon goes into a mode with dotted lines, but the events refuse to fire during edit.
Update: if I enable the edit button, the draw:edited event fires. this is a workaround, but will have to do for now.
TLDR: draw:drawstop is not firing at all when it is supposed to be

we can bind the edit event to the polygon layer. this does what I'm after


[Bug]: Unsupported class file major version 61

Platform
Android 12
Plugin
connectivity_plus
Version
5.0.0
Flutter SDK
3.13.2
Steps to reproduce
Using version 5.0.0
Android Studio compilation encountered an error
Cause 1: org.gradle.api.GradleException: Failed to create Jar file /Users/kjt/.gradle/caches/jars-8/947c1318c2bb7024446bea1314544a0f/lint-model-31.1.2.jar.
Caused by: java.lang.IllegalArgumentException: Unsupported class file major version 61
Code Sample
No response
Logs
FAILURE: Build failed with an exception.

* What went wrong:
A problem occurred configuring project ':connectivity_plus'.
> Failed to create Jar file /Users/kjt/.gradle/caches/jars-8/947c1318c2bb7024446bea1314544a0f/lint-model-31.1.2.jar.
> Failed to notify project evaluation listener.
   > Could not get unknown property 'android' for project ':connectivity_plus' of type org.gradle.api.Project.
   > Could not get unknown property 'android' for project ':connectivity_plus' of type org.gradle.api.Project.

Cause 1: org.gradle.api.GradleException: Failed to create Jar file /Users/kjt/.gradle/caches/jars-8/947c1318c2bb7024446bea1314544a0f/lint-model-31.1.2.jar.

Caused by: java.lang.IllegalArgumentException: Unsupported class file major version 61

Flutter Doctor
[✓] Flutter (Channel stable, 3.13.2, on macOS 13.5.1 22G90 darwin-arm64, locale zh-Hans-CN)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.1)
[!] Xcode - develop for iOS and macOS (Xcode 15.0)
    ✗ Unable to get list of installed Simulator runtimes.
[✓] Chrome - develop for the web
[✓] Android Studio (version 2021.2)
[✓] Android Studio (version 2021.2)
[✓] Android Studio (version 2022.3)
[✓] IntelliJ IDEA Community Edition (version 2022.3.2)
[✓] Connected device (3 available)

Checklist before submitting a bug

[X] I searched issues in this repository and couldn't find such bug/problem
[X] I Google'd a solution and I couldn't find it
[X] I searched on StackOverflow for a solution and I couldn't find it
[X] I read the README.md file of the plugin
[X] I'm using the latest version of the plugin
[X] All dependencies are up to date with flutter pub upgrade
[X] I did a flutter clean
[X] I tried running the example project

I would appreciate if you really used search in Google and among issues in this repo before opening such bug reports.
There were tons of same issues already and it is connected with your project using old Android Gradle Plugin version (older than 4.2). Update it and everything will work again.


Create nuget package at build time

to make it easy for portabilityservice to consume at local development time.

Test failed for missing ilasm in the output directory. It is a known .NET Core SDK issue, has been fixed in SDK3.0. https://github.com/microsoft/dotnet-apiport/pull/808 is a fix to work around the issue.


chore: delay page dsl calls

Description
Since our old entity explorer listed entities from all the pages, we had to make API calls to fetch dsl of all the pages. With the new entity explorer, this can be called at a much later stage.
This PR contains the changes to make fetch DSL API calls, when the navigate section in omnibar is open, since it is the only place where we list entities from other pages today.
Fixes # (issue)
Type of change

Perf fix

How Has This Been Tested?

Manual

Checklist:

[ ] My code follows the style guidelines of this project
[ ] I have performed a self-review of my own code
[ ] I have commented my code, particularly in hard-to-understand areas
[ ] I have made corresponding changes to the documentation
[ ] My changes generate no new warnings
[ ] I have added tests that prove my fix is effective or that my feature works
[ ] New and existing unit tests pass locally with my changes

Test coverage results :test_tube:
:green_circle: Total coverage has increased
// Code coverage diff between base branch:release and head branch: chore/delay-page-dsl-calls

Status
File
% Stmts
% Branch
% Funcs
% Lines

:green_circle:
total
56.37 (0.02)
37.76 (0.03)
35.96 (0.02)
56.58 (0.01)

:red_circle:
app/client/src/actions/pageActions.tsx
67.96 (-0.04)
25 (0)
25.81 (-0.86)
57.75 (-0.22)

:green_circle:
app/client/src/components/editorComponents/GlobalSearch/index.tsx
53.15 (0.63)
17.53 (0.69)
35.59 (1.11)
55.25 (0.27)

:green_circle:
app/client/src/pages/Editor/Explorer/common.tsx
100 (9.09)
100 (0)
100 (100)
100 (9.09)

:green_circle:
app/client/src/pages/Editor/Explorer/Files/index.tsx
78.95 (2.63)
41.67 (8.34)
60 (20)
83.33 (2.77)

:green_circle:
app/client/src/pages/Editor/Explorer/Widgets/WidgetGroup.tsx
100 (5.88)
76.06 (1.41)
100 (0)
100 (6.06)

:green_circle:
app/client/src/sagas/InitSagas.ts
51.15 (3.02)
36.67 (3.83)
58.33 (0)
54.79 (3.2)

:red_circle:
app/client/src/sagas/PageSagas.tsx
24.06 (-0.15)
5.38 (0)
14.29 (0)
25.59 (-0.16)

:green_circle:
app/client/src/utils/WorkerUtil.ts
89.76 (0.78)
72.55 (1.96)
100 (0)
93.33 (0.95)

:green_circle:
app/client/src/utils/autocomplete/TernServer.ts
52.94 (0.23)
41.67 (0.84)
36.21 (0)
56.99 (0.25)

/ok-to-test sha=57b5a10

/ok-to-test sha=a4726ea

/ok-to-test sha=25845c0

/ok-to-test sha=8288e9f

/ok-to-test sha=c6c5e74

/ok-to-test sha=0c4dde2

/ok-to-test sha=777379c


Week 2 Review Ticket

Individual GitHub pages (3 points)
GitHub page that documents key learnings and code snippets using GitHub and replit
Organize files, directories and menus for the first 3 weeks.
Write Factorial function using classes, providing implementation of call.
Select your own Math function. Write it in Imperative and OOP form.
Extra Credit(1 point).  Write Palindrome function using classes, must provide implementation of call.  Must indicate where error occurs on front and back comparison.

3/3, had everything


Options before arguments

Many command line tools require that options come before arguments. When giving options in sh via keyword arguments, there does not seem to be any way (something like _options_first=True) to make sure that the program is called correctly. Of course, it is still possible to give the options to sh in their string form, but that isn't very nice.
Basically, I would like something like
from sh import ls
ls('/', l=True, _options_first=True)

to execute ls -l / insead of ls / -l. I don't want to have to resort to ls('-l', '/')

I think _options_first is a very specific option...I'm thinking maybe too specific.  It also wouldn't handle interleaving positional and keyword arguments, something that somebody would eventually request.
I see the usefulness of specifying an argument easily programmatically, and it is indeed easier to specify a argument with a keyword argument than it is a string, but I don't think that alone warrants a new specific option.
I do think this plays into another feature though I've been thinking about for the past year, so thank you for bringing it up.

Can you please consider reopening this issue?
There is a common pattern that many shell commands support to safely allow passing positional arguments that may contain a leading hyphen. The following command deletes a file named -rf and does not interpret it as a command line argument:
rm -- -rf

If sh supported _options_first I could do either:
from sh import rm
untrusted_input = "-rm"
rm('--', untrusted_input, _options_first=True)

# or with bake:
safe_rm = rm.bake('--', untrusted_input)
safe_rm(untrusted_input)

# I think this is the only way to safely pass arguments like this today:
def safe_rm(*args, **kwargs)
    return rm.bake(**kwargs).bake('--')(*args)

Without something like _options_first it is not possible to safely pass untrusted arguments to many shell commands.
Adding #53 for reference too, which is similar.

Hi @bburky
Why doesn't rm('--', '-rf') work correctly as-is?

Rm is just an example. Realistically I would want to pass some additional parameters using sh's kwargs support. I cannot currently easily do this if I want to use a -- parameter before my positional args with them at the end.

Oh I see.. right, if you wanted additional args to rm, yes they could not be keyword arguments. Looking back at my comment from 2016, I think I still agree with my position. If there was an _options_first special arg, it doesn't handle interleaving some kwargs before args, and some kwargs after args. So I don't like it as a general solution to the problem.
I think if you want fine grained control, including the special case of "all kwargs before args", your best bet is still to use .bake() to bake the exact order that you want, or use the string version (instead of the kwarg version) and order them as needed. It's clunky, but the problem is also clunky. A wrapper like you wrote with safe_rm is a totally valid way to call more complicated sh functions as well.


Rule request: has-own-property

TypeScript code being linted
const container = { a: "a", b: "b", hasOwnProperty: () => false };

for (const i in container) {
    if (container.hasOwnProperty(i)) {
        console.log(container[i]);
    }
}

Expected behavior
container.hasOwnProperty isn't guaranteed to work as expected, since the object might override it. You're better off using {}.hasOwnProperty.call(container, i) (or, as TypeScript prefers, Object.prototype.hasOwnProperty.call(container, i).
Docs of this rule should probably also recommend the user consider using a Map.

You can use the ban rule to that effect then make use of something like Object.getOwnPropertyDescriptor(container, i) !== undefined (you can even omit the !== undefined part)

Ooh, that should work for most scenarios.
One corner case: if someone coincidentally has a member function named hasOwnProperty and wants to use it. That seems like a dangerous idea. Adding an example to the ban rule that explains both the reasons to ban hasOwnProperty and why you shouldn't name your methods that should be good.


there is a api that can get the hdfs disk usage summary?

anyone can help me ?

I believe you should be able to extract that sort of information from the cm_api time-series resource

Unfortunately, the API to get the HDFS disk usage summary are not exposed in the public API yet.

got


fix kotlin build problem

Build fails for android because of nullability.

included https://github.com/KasemJaffer/receive_sharing_intent/pull/140

Fixed in later versions

@KasemJaffer
No. 1.4.4 also crashes on build:
e: /home/yaroslav/.pub-cache/hosted/pub.dartlang.org/receive_sharing_intent-1.4.4/android/src/main/kotlin/com/kasem/receive_sharing_intent/ReceiveSharingIntentPlugin.kt: (146, 78): Type mismatch: inferred type is Uri? but Uri was expected
e: /home/yaroslav/.pub-cache/hosted/pub.dartlang.org/receive_sharing_intent-1.4.4/android/src/main/kotlin/com/kasem/receive_sharing_intent/ReceiveSharingIntentPlugin.kt: (207, 95): Only safe (?.) or non-null asserted (!!.) calls are allowed on a nullable receiver of type String?

@KasemJaffer
The issue still exists. I think the changes by @LazyDave76 should be reviewed and merged.
It doesn't look nice that you just closed this issue without respecting his contribution.

@KasemJaffer
The issue still exists. I think the changes by @LazyDave76 should be reviewed and merged.
It doesn't look nice that you just closed this issue without respecting his contribution.

Thanks for the support @kaboc :)  I was surprised to see it closed too - I fixed bugs in iOS and Android.
@proninyaroslav copied and opened the pull request https://github.com/KasemJaffer/receive_sharing_intent/pull/145 maybe that one will be approved.

@KasemJaffer
This is still an issue! Please merge this!


Bug: QA Import from Historical

Issue:
User received 288 Import Errors
Note: Might just be an issue with rata traverse files
Steps to Recreate:

Check out Brandon Shores 1
Revert Brandon Shores
Go To Import Historical QA
Import 2022 Q4 All Tests
288 Import Errors Generated

Private Zenhub Image

Received no Import errors


[RS-2023] Change services permissions to deployments permissions

Description
Changing the WAF UI to list deployments instead of services means services are not longer needed in the rbac but deployments are.

For PR author

[ ] Tests for change.
[ ] If changing pkg/apis/, run make gen-files
[ ] If changing versions, run make gen-versions

For PR reviewers
A note for code reviewers - all pull requests must have the following:

[ ] Milestone set according to targeted release.
[ ] Appropriate labels:

kind/bug if this is a bugfix.
kind/enhancement if this is a a new feature.
enterprise if this PR applies to Calico Enterprise only.

This looks good from my perspective.


Aliased generics. For a better future

So, I'm still in the process of reviewing your contributions, but I will say that it seems your changes have made the tests take so many hours to complete, that they simply time out.
Because performance is of the utmost concern, I'll need to look into where the degradation is coming from. Go is all about performance, and as the author of package generics, I cannot let the theoretical millions of gophers who rely on this package down.

I've read on the Internet that if I close and reopen the PR Travis will try again

Dear Maintainer,
Seeing how it's of utmost important to ensure widespread usability and testability of this package,
I took the liberty to further add to the package testing suite the missing Go versions.
I hope that my actions will be rewarded with some of that sweet sweet acceptance into this select club of contributors as I'm trying to make these changes available for everyone.
Please let me know if these changes are now up to the high standards imposed by this project and if not, how I can improve my work so that this becomes part of the Source.
Thank you.
Yours truly,
@dlsniper

An additional question for the opener of the PR:
With the current build tag solution, will the go1.9 build continue to be chosen for 1.10, 1.11, 1.12, etc?
Or as commenter K Nova suggests, do we need a more robust solution?
Excited to see where this PR goes! A backwards compatible but future-thinking change is exactly the kind of fresh thinking lifeblood that package generics needs to stay alive in this competitive climate!


chore(release): prepare for release

Description
android_alarm_manager_plus and android_intent_plus didn't need to have breaking release as they are still Java based.
I have already retracted 4.0.0 and 5.0.0 of these plugins from pub.dev and plan to release new versions as minor version bump.

Will fix bootstrapping for these plugins in nearest days as it is a second time melos bootstrap fails for android_... pugins


Add apic icons

Add icons created specifically for API Connect landing pages
Create separate section and demo page to showcase API Connect

Note: Icons are not displayed on the main page because we are officially releasing the icons in batches - just going ahead and adding these as special purpose icons so they can be used in product

I have read the DCO document and I hereby sign the DCO.

I have read the DCO document and I hereby sign the DCO.


Support language features in metadata / decompiled source files

Currently it looks like all metadata as source files are going into the LSP misc workspace. This appears to be because TryAddDocumentToWorkspace never gets called. In VS this is called when the file is opened (the misc files workspace sees it and puts the document in the workspace). Since a solution is never created in the metadata workspace because the file is never added, the metadata workspace is also not registered.

Scenarios here

Go to definition from metadata references
Document outline - https://github.com/dotnet/vscode-csharp/issues/6341

Is there any update on this?  This seems like a pretty big miss from a feature-parity perspective and it's been several months since this ticket was updated.

Just encountered #6021 but only for some projects in a solution.
I'm on version 2.22.5 and everytime I reload the window, the C# output pane shows this:
Using dotnet configured on PATH
Dotnet path: /usr/share/dotnet/dotnet
Activating C# + C# Dev Kit...
waiting for named pipe information from server...
[stdout] {"pipeName":"/tmp/c8da874b.sock"}
received named pipe information from server
attempting to connect client to server...
client has connected to server
[Info  - 3:42:10 AM] [Program] Language server initialized
[Error - 3:42:11 AM] Request textDocument/semanticTokens/range failed.
  Message: Unsupported extension '' and LSP language id ''
  Code: -32000
[object Object]
[Error - 3:42:11 AM] Request textDocument/semanticTokens/range failed.
  Message: Unsupported extension '' and LSP language id ''
  Code: -32000
[object Object]

Still not solved?

This should be available in the next prerelease update to the extension.  Will update here once it is published.

This should now be available in v2.41.26 (pre-release).

@SherbetHead yeah there is an issue with sourcelink in the latest version.  We're working on a fix and should have it out this week.

What's the status on this? It's frustrating only being able to navigate one level deep into decompiled code.

@HunterZ this should be available in the latest versions of the extension (either release or prerelease).  If you're having problems on the latest version, would you mind filing a new issue?  Would be helpful to include the C# logs - https://github.com/dotnet/vscode-csharp/blob/main/SUPPORT.md#collecting-general-logs as well as any information on where the symbols you're navigating to are coming from.

After having never worked, this suddenly seems to have started working a few days ago. I guess it just took 2-3 months to get into a release version.


ReceivedCharacter not sent for non ascii characters on osx

Typing é, for example, doesn't trigger the ReceivedCharacter event.
I blame this line: https://github.com/tomaka/glutin/blob/3246613a51568073e40ee99efeb0c76c36db3ecc/src/api/cocoa/mod.rs#L840

@paulrouget that is only one part of the problem. While it will allow you to receive characters created with shift + alt, it will ignore composing characters such as ¨ + a -> ä and IME input.
GLFW ignores this functionality, while SDL2 adds an invisible textfield which has all the normal text input capabilities you'd expect. If we were to replicate that there would have to an API change in the form of start_text_input() and ´stop_text_input()´ to tell glutin when the text field should be focused.

that is only one part of the problem

Absolutely. But it's still an improvement.
I'll file an issue for composed characters.

But it's still an improvement.

Agreed! Kind of curious how that line got there in the first place..

Fixed in #722.


49 dolphins returned

49 sort is back

Thank you for your contribution to the KodaDot NFT gallery,
we really appreciate your contribution!

PR type

[ ] Bugfix
[x] Feature
[ ] Refactoring

Before submitting this PR, please make sure:

[x] Your code builds clean without any erros or warnigns
[x] You've posted screenshot of demonstrated change in this PR
[x] Merged recent default branch, main and you have no conflicts
[x] Didn't break any original functionality

Optional

[ ] You've tested it on mobile
[ ] Are there any edge cases? Name if any

Thanks for the review @roiLeo  ^-^
Let's ship it then 🚢


Unsupported location when running power shell command

Trying to play around with Azure Machine learning power shell command. But get this error:

Get-AmlWorkspace : Unsupported location: South Central US (or other supported region)
At line:1 char:1

Get-AmlWorkspace

  + CategoryInfo          : NotSpecified: (:) [Get-AmlWorkspace], Exception
  + FullyQualifiedErrorId : System.Exception,AzureML.PowerShell.GetWorkspace

How can I avoid this issue?

Ahh. Get it. I need to specify the config.json file correctly.


fix(33377): completions for string literals don't follow quoteStyle preference

Fixes #33377

@sheetalkamat this is ready to go, right?

Seems this PR resolves two issues
#33377
#31507
cc @sandersn @sheetalkamat @DanielRosenwasser

(I edited the description to include the second bug)


Transpose function

The transpose function transposes the rows and columns of its argument. For example,
transpose applied to [[1,2,3],[4,5,6]] returns [[1,4],[2,5],[3,6]]
If some of the rows are shorter than the following rows, their elements are skipped:
transpose applied to [[10,11],[20],[],[30,31,32]] returns [[10,20,30],[11,31],[32]]
I'm planning to submit a PR for this.
What do you think?

If some of the rows are shorter than the following rows, their elements are skipped

I wonder how could this, as a default behaviour, could be practically useful that the output doesn't confuse or surprise anyone?

I wonder how could this, as a default behaviour, could be practically useful that the output doesn't confuse or surprise anyone?

For me sounds natural to ignore "empty elements". Haskell's transpose behaves this way.
But I agree that we should give the user more overloads, so I also think about one overload where user can provide an T value for fill the gaps and maybe another overload that throw an InvalidOperationException when use pass a matrix where some of the rows are shorter than others...
Summary: this is the overloads I imagine:

ingnore empty: [[10,11],[20],[],[30,31,32]].transpose() returns [[10,20,30],[11,31],[32]]

IEnumerable<IEnumerable<T>> Transpose<T>(this IEnumerable<IEnumerable<T>> source)

fill empty with value provide: [[10,11],[20],[],[30,31,32]].transpose(X) returns [[10,20,X,30],[11,X,X,31],[X,X,X,32]]

IEnumerable<IEnumerable<T>> Transpose<T>(this IEnumerable<IEnumerable<T>> source, T emptyRepresentation)

throw exception: [[10,11],[20],[],[30,31,32]].transpose() throws Exception
????

Need help for define the Exception overload.
Why do you think about the overloads?

For me sounds natural to ignore "empty elements"

If it sounds natural to you then care to explain why so? :smile: What are the corner cases of skipping or not skipping? Just because Haskell does it that way doesn't mean we should copy without understanding the value proposition of that as a default. Also, think about the implications if one list is infinite.
I'm not in favour of the overloads. Transpose is like a ZipMany or Zip for list of lists and the way we did this for Zip is to have a separate method for each distinct behaviour (EquiZip, ZipLongest & ZipShortest). See #24 and #6 for background and discussion. It would seem to me that it's better to do the same here instead of overloading.

If it sounds natural to you then care to explain why so? :smile:

I talked with with some friends about it and that is what I heard:

"IEnumerable don't have the concept of "empty elements", so is natural jut ignore it"

"Since IEnumerable's, may have different length, make sense the result IEnumerable's also have different length. I would expect the "empty elements" would be keep if the transpose signature was for two dimensional array (e.g., double[ , ])"

"Since tranpose (in math) is just for matrix (list of equal-length lists), there is nothing defined about nonrectangular matrix (list of different-lenght lists)... so any behavior is acceptable because there isnt a standard".

I agree manly with the first two thoughts.

Also, think about the implications if one list is infinite.

I already have a sketch of transpose's implementation (ingnoring empty and pad overloads), both works with infinit list of infinit lists. I tested with something like:
var table = NaturalNumbers().Select(n => new InfiniteSequence(n));

foreach (var inner in table.Transpose().Take(3).Select(x => x.Take(9)))
{
    foreach (var x in inner)
    {
       Console.Write(x + " ");
    }
    Console.WriteLine();
}

The output was the expected:
0 1 2 3 4 5 6 7 8
0 1 2 3 4 5 6 7 8
0 1 2 3 4 5 6 7 8

have a separate method for each distinct behaviour

I consider distinct methods when the overloads signrature and its documentation by itself are not enough to distinct each behavior (or if becames too much complicated).
In my opinion, the difference between the first 2 overloads can easyly be understand. Only EquiTranspose receive a different name to explicit its potentially dangerous behavior and avoid user mistakes.

Transpose<T>(this IEnumerable<IEnumerable<T>> source)
Transpose<T>(this IEnumerable<IEnumerable<T>> source, T pad)
EquiTranspose<T>(this IEnumerable<IEnumerable<T>> source)

@atifaziz what do you think about target TransposeShortest and TransposeLongest to release 2.4 ?

@leandromoh I don't think this one has been completely thought out yet.

I had understood the problem was define which overload would be the default.
However, since we will use differents methods instead of overloads, I thought the problem was solved.
What do you think is missing to define?

@atifaziz I would like to submit a PR only for the transpose method that ignore empty entries, for now. What do you think? The method name can bem defined ar PR time.
[[10,11],[20],[],[30,31,32]].transpose() returns [[10,20,30],[11,31],[32]]


Core: RunnableEach Docstring

Solves the following Privileged issue: #16632
@eyurtsev

@keenborder786 I am unable to merge this PR since the original branch was deleted from your fork. Would you be willing to open another PR?

@eyurtsev yes I don't know what happened.

Something wrong with github.

@eyurtsev  please check


WIP: chore: added posterior decoding and updating the tagger decoder API, add tests

This PR updates the API for the tagger decoders. There is still some more work to do but I wanted to get comments on it earlier rather than later.

It creates a separation between taggers that do structured prediction vs locally normalized models.
It adds to the decoder API to:

get normalization factor at each timestep
get the normalization factor going backwards
Get the posterior distribution from the taggers
Decode based on the posterior

It adds a lot of tests

Adds tf2 tests for the tagger decoders
Adds more batch stability tests to the pytorch decoder
Add tests that compare the computed values between the tf/pyt version and explicit python code

It also sets the EOS tag at the end of the unary/tags for tensorflow so that we don't output illegal tags at the end of the sequence (B-X at the end, etc.)

This doesn't touch the main path though the code (the partition function and the viterbi decoder) so I don't think is should a big burden to merge.
There are still a few things to do before merging.

[ ] Add the partition functions to the tensorflow ConstrainedGreedyTaggerDecoder
[ ] Add pytorch tests for the constrained decoder taggers
[ ] Add test for tf1
[ ] Add tensorflow tests for the constrained decoder taggers
[ ] Add pytorch tests for normal greedy decoder (score sentence, etc)
[ ] Add tensorflow tests for normal greedy decoder (score sentence, etc)

Closing as feature/v2 branch is getting removed


example updates

I can't figure out how the bibliography works, but this needs to be added for CD-HIT:
"Cd-hit: a fast program for clustering and comparing large sets of protein or nucleotide sequences", Weizhong Li & Adam Godzik Bioinformatics, (2006) 22:1658-9.


About distance of RealSense D435

I want to add a program to display the distance between the center of the screen and the camera in the code below with realsense D435.
Is there a better way?
#include "opencv2/opencv.hpp" #include "opencv2/highgui.hpp" #include <vector> #include <librealsense2/rs.hpp> #include <iostream> #include <stdio.h> using namespace cv; using namespace std; int main(int argc, char * argv[]) { 	int width = 640; 	int height = 360; 	int fps = 15; 	float dist_to_center; 	rs2::config config; 	config.enable_stream(RS2_STREAM_INFRARED, width, height, RS2_FORMAT_Y8, fps); 	rs2::pipeline pipeline; 	rs2::pipeline_profile pipeline_profile = pipeline.start(config); 	CascadeClassifier cascade; 	cascade.load("C:/opencv/sources/data/haarcascades/haarcascade_frontalface_alt.xml"); 	vector<Rect> faces; 	while (1) 	{ 		rs2::frameset frameset = pipeline.wait_for_frames(); 		rs2::video_frame ir_frame = frameset.get_infrared_frame(); 		cv::Mat dMat_left = cv::Mat(cv::Size(width, height), CV_8UC1, (void*)ir_frame.get_data()); 		cascade.detectMultiScale(dMat_left, faces, 1.1, 3, 0, Size(20, 20)); 		rs2::depth_frame depth = frameset.get_depth_frame(); 		for (int i = 0; i < faces.size(); i++) 		{ 			rectangle(dMat_left, Point(faces[i].x, faces[i].y), Point(faces[i].x + faces[i].width, faces[i].y + faces[i].height), Scalar(0, 0, 0), 3); 		} 		imshow("img", dMat_left); 		char c = cv::waitKey(1); 	} 	return EXIT_SUCCESS; }

Hi @Vermilion016  A C++ / OpenCV script at https://github.com/IntelRealSense/librealsense/issues/6239#issuecomment-615249398 for getting the pixel at the center of an object may be a helpful reference.

I'm sorry. I failed.
I actually tried the sample code in the link below. It worked it, but I couldn't union it with the original code.
'p.start();'
'pipeline.start();'
It seems that it was useless this part.
https://dev.intelrealsense.com/docs/rs-hello-realsense

There is no need to be sorry.  :)
If you attempted to merge the rs-hello-realsense project into your own project then it may have failed to build because of the CMakeLists.txt file of rs-hello-realsense not having the necessary details to locate the librealsense library files.  The link below has a version of rs-hello-realsense with a more complex CMakeLists.txt file that can work as a standalone build.
https://github.com/zivsha/librealsense/tree/getting_started_example/examples/getting-started

I'see. I will try.
Thank you very much.

Hi @Vermilion016  Do you require further assistance with this case, please?  Thanksl

This method was unsuccessful, but other methods may be substituted.
Thank you for your cooperation. Mr. Marty G.

Do you need further suggestions about how to solve your problem, please?

Case closed due to no further comments received


Errors in the Building RPMs documentation

http://docs.clusterhq.com/en/latest/gettinginvolved/infrastructure/packaging.html

The spec filename is wrong. Should be sudo yum-builddep python-flocker.spec
...also rpmbuild -ba python-flocker.spec
yum-builddep python-flocker.spec installs a version of Characteristic which is too new.

[vagrant@localhost flocker-662]$ yum info python-characteristic
Installed Packages
Name        : python-characteristic
Arch        : noarch
Version     : 14.1.0
Release     : 1.fc20
Size        : 127 k
Repo        : installed
From repo   : tomprince-hybridlogic

The rpmbuild step then fails

[vagrant@localhost flocker-662]$ rpmbuild -ba python-flocker.spec
error: Failed build dependencies:
	python-characteristic = 0.1.0 is needed by python-flocker-0.2.0-0.2.pre.fc20.noarch

We are moving our development planning to JIRA. This issue is now being tracked at https://clusterhq.atlassian.net/browse/FLOC-814. You are welcome to file additional issues in GitHub if that's easier for you.


Moving tilt to use helm instead of static yaml

TODO:

[x] remove old test/kubernetes.yaml
[x] check if ingress-nginx can be changed to helm
[x] pin versions on all helm charts
[x] rebase
[x] README updates

@Kaezon can you give a quick overview? I wanted to merge this before I forget all about this PR.

Yes, sorry. I let this fall off my plate. I'll go back over it now.


[bug] Attribute error on ctx.get_all()

Running this snippet produces the following error:
def process_embeddings(code: str):
	client = bblfsh.BblfshClient("<IP_ADDRESS>:9432")
	ctx = client.parse("arbitrary.java", language="java", contents=str.encode(code))
	print(ctx)
	print("Type of ctx:", type(ctx))
	resdict = ctx.get_all()
	return resdict

ctx prints as expected, but the type seems to be incorrect, which causes an Attribute Error to be thrown.
The parse method signature is: def parse(self, filename: str, language: Optional[str]=None, contents: Optional[str]=None, mode: Optional[ModeType]=None, timeout: Optional[int]=None) -> ResultContext:
I was expecting the type to be ResultContext, but type(ctx) produced <class 'gopkg.in.bblfsh.sdk.v1.protocol.generated_pb2.ParseResponse'>.
I think this is the root cause of the Attribute Error, but I was unable to debug the issue further.
Traceback (most recent call last):
  File "main.py", line 202, in <module>
    main()
    └ <function main at 0x11558c268>
  File "main.py", line 188, in main
    feature_set = extract_features(submissions)
                  │                └                                                     code                 author
0              public static void doNothing() {\...
                  └ <function extract_features at 0x1029fb048>
  File "main.py", line 50, in extract_features
    metrics, new_docSpace_additions = extract_metrics(code)
                                      │               └ 'public static void doNothing() {\n    \n}'
                                      └ <function extract_metrics at 0x10b60d840>
  File ".../controller.py", line 63, in extract_metrics
    metrics['embeddings'] = process_embeddings(code)
    │                       │                  └ 'public static void doNothing() {\n    \n}'
    │                       └ <function process_embeddings at 0x114a77d90>
    └ {'identifiers': {'raw_identifiers': [], 'identifier_freq': Counter(), 'is_camel_caser': True, 'num_unique_identifiers': 0, 'avg_...
  File ".../embeddings.py", line 14, in process_embeddings
    resdict = ctx.get_all()
              └ elapsed {
  nanos: 10864400
}
uast {
  internal_type: "CompilationUnit"
  children {
    internal_type: "TypeDeclaration"
    pr...
AttributeError: get_all

Related to v1 API. See examples for the currently supported v2.


DataSet.crosstab should support lists

Any of these should be possible via auto-pd.concat:
dataset.crosstab(['q1', 'q2'], 'q3')
dataset.crosstab('q1', ['q2', 'q3'])
dataset.crosstab(['q1', 'q2'], ['q3', 'q4'])

additionally a few new features are added (like adding stats + sigs)

tests are failing for chains. need to check next week!

to get all old functionalities, rbase is needed (draft for ViewManager regarding rbase is added).
ChainManager does not support rbase yet, Chain.get() does not merge the frames properly. @alextanski can we have a look together?

@alextanski branch i1216_dataset_crosstab is up-to-date
DataSet.crosstab2() is my new crosstab version, which currently ignores rbase
ViewManager.set_bases() is updated, so it takes rbase into account if requested

I'm a big user of DataSet.crosstab I really like it. I second the request about, it would be good to have the option to hide rbase,  but also to show weighted and unwieghted rbase counts (even on % crosstabs)

Sorry I'm a little confuesed by the thread. Are people saying that their currently is a way to do lists in cross-tabs (like in Pandas) or are they saying that their should be in the future? If it's currently possible could someone provide me with some additional guidance?

@Havlin in the current master or develop version crosstab does not support lists, but it should be possible in future.
Currently there is a new crosstab method DataSet.crosstab2() in branch i1216_dataset_crosstab, that does support lists, but it's not fully tested and row-bases (which are available in the current method) are not working.

Thanks @nitsrek . Could you provide me the file location where I can find  the underlying code for crosstab2? I was poking through i1216 but was unable to find it.
Also, what do you mean by 'row-bases'? Do you mean that it doesn't provide totals in the table?