Render default skin for 404

Great service! I'd love to use it for a website I'm building, but I noticed that players without a custom skin show up as a 404 error.

HTTP ERROR: 400

Problem accessing /full/512/yadayada.png. Reason:

Could not find a player named 'yadayada'
Powered by Jetty:// 9.3.0.RC0

Other player avatar services (e.g. Minotar) show the default player skin (Steve) when no custom skin is found for a player. This would be ideal so that I can embed images without worrying about handling 404 responses.

There's a difference between players without a custom skin and players that do not exist.
It's inconsistent though, because passing a UUID (which you really should do instead of using names) just renders Steve/Alex instead of returning an error.
btw, it's returning a 400 Bad Request, not a 404 Not Found :sunglasses:

Ahh whoops! Thanks for catching that.
In that case, what are your thoughts on returning a skin/render regardless of the error when the requested URL ends in .png? I would expect that to always be an image rather than a text/html response.

In the case of browsers (which is the primary Visage use case) it will simply result in a "broken image" placeholder icon if it's the wrong mimetype.
Jomo is also right in the fact that there is a (surprisingly big) difference between players which don't exist and those without a skin. I tested Visage with multiple accounts without set skins early in development, and that is also how X-Steve and X-Alex are implemented; dummy odd and even UUIDs without skin payloads.
And the odd/even thing is actually why this can't work; if I can't get a texture payload, I need to decide which skin to use. If I have a UUID, it's quite simple; if it's even, I use Steve. Odd is Alex.
Without a UUID, I have to make one up on the fly, throw an error, or use a specific skin. None of those solutions are particularly good.
Proposed solution: Use UUIDs. I may fix this in the Visage+ upgrade that I'm currently working on.

I understand.
If I make the switch to UUIDs (which I intend to do and was using player names for prototyping/simplicity), it'll be my responsibility to handle the case of non-existent players. And when thinking about this more, maybe it should be my responsibility :)
My particular use case is player profiles where the player names come from whatever servers publish as part of their player list. In some cases, I'm seeing names appear that aren't actually real players (or come up as 400 errors) and wondering if they're spoofed or something.

Oh I hear you @unascribed. I'm working on a very similar project and we've gone through all these issues as well. Using usernames causes a whole bunch of problems.
FYI: KrisJelbring might consider adding a proper API endpoint.

wondering if they're spoofed or something

It might be offline-mode servers. Spoofing the online list is also possible, some plugins do this to add some custom info. It's also possible that some of the users renamed their accounts while logged in on a server, which still has their old name. Anyway, just use UUID :)

:+1:


authors with x-initials may have no affiliation

Some Persons with x-initials are not affiliated with any department. The cat-none css class does not render correctly in the people's view.

related #74


Remove Surface fill prop

Remove the fill prop from the <Surface> component because it
causes errors of the form
https://github.com/clintonbembryjr/react-neu/issues/4
The page looks identical without this prop

On a related note, we may consider moving off of the https://www.npmjs.com/package/react-neu dependency because it doesn't see much usage (26 downloads this week, last release 10 months ago).

100%. This is something we inherited as we forked our repo from YAM's UI.


 Its not crashing everytime sometimes ist just doing Nothing.
What happens:
After a couple of seconds the Server crashes with a error in the console
What you expected to happen:
That the Server is not crashing and my friend just dies normally without crashing the whole Server.
Steps to reproduce:
1.Put your Server in Offline-mode
2.Kill your friend and there is a Chance that the Server dies

Affected Versions

EnderIO: 5.0.50
EnderCore: 0.565
Minecraft: 1.12.2
Forge: <IP_ADDRESS>38
SpongeForge? Yes (HexaCord)
Optifine? No optifine is not Installed.
Single Player and/or Server? Its on a Server.

-----Crash Report----
CrashReport.txt
-----Latest Log-----
latest.log

how do you think this is an EIO issue?! There is no trace of anything relating to EIO being the issue!?
Does this happen in online mode?!
because in the report it LITERALLY says * Offline mode for dedicated servers is NOT supported by Ender IO.

Offline mode is not supported. Additionally, this crash doesn't seem to be caused by Ender IO at all--I find it much more likely to be caused by Sponge or one of your plugins. Something to do with the scoreboard.
Also, in the future, please upload your logs to a site like pastebin or gist, rather than uploading the files themselves, like the template says.

looks like this is this crash: https://github.com/SpongePowered/SpongeForge/issues/2817


PagerDuty Vendor Key issue

the PD vendor key starts with a number, which causes the entrypoint script to write it as an invalid python variable.  I'm not super familiar with bash switch statement evaluations but I'm going to take a stab at fixing it.

I think I'm just using the wrong value.


chore(deps): Bump falcoctl in registry binary to resolve CVE-2022-1996 in indirect dependency github.com/emicklei/go-restful

What type of PR is this?

Uncomment one (or more) /kind <> lines:

/kind feature

/kind bug

/kind cleanup

/kind design

/kind documentation

/kind failing-test

Any specific area of the project related to this PR?

Uncomment one (or more) /area <> lines:

/area rules

/area registry
/area build

/area documentation

Proposed rule maturity level

Uncomment one (or more) /area <> lines (only for PRs that add or modify rules):

/area maturity-stable

/area maturity-incubating

/area maturity-sandbox

/area maturity-deprecated

What this PR does / why we need it:
Bumps the falcoctl package in the registry go.mod to resolve CVE-2022-1996 in the indirect dependency github.com/emicklei/go-restful
Which issue(s) this PR fixes:

Fixes #
Special notes for your reviewer:

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: tspearconquest
Once this PR has been reviewed and has the lgtm label, please assign mstemm for approval. For more information see the Kubernetes Code Review Process.
The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

Welcome @tspearconquest! It looks like this is your first PR to falcosecurity/rules 🎉

I also ran go mod tidy which is why so many lines are removed; looks like a ton of dependencies changed between falcoctl v0.3.0-rc5 and v0.5.1

@LucaGuerra when you are back and @maxgio92

/lgtm
JFI https://github.com/falcosecurity/rules/pull/105 also bumps falcoctl furher

LGTM label has been added.  Git tree hash: 1b3cc00ea2d3abd2fe14a6e7fbfe8a54b2560377


Words "left" and "right" flipped in selectors before a comma

Consider this example
[class*="span"].pull-right,
.row-fluid [class*="span"].pull-right {
  float: right;
}

the code doesn't take the ","  as end of rule and therefor transform it as well.
I'm kindda new to Regex but I came up with this solution for now :
lookAheadNotLetterPattern = '(?![a-zA-Z]|[\\,])'

@NiviJah A comma , cannot be the end of a rule in valid CSS. A rule is either ended explicitly with a semi-colon ; or implicitly by the closing curly brace }.
What bug are you experiencing? The given example seems to flip without problems.
https://cssjanus.github.io/#input/[class*%3D"span"].pull-right%2C
.row-fluid [class*%3D"span"].pull-right {
  float%3A right%3B
}
/* CSSJanus output */

[class*="span"].pull-left,
.row-fluid [class*="span"].pull-right {
  float: left;
}

@Krinkle In the example, the first use of the selector ".pull-right" is being flipped to ".pull-left", which is not the typical or expected behaviour. (Note that this is fixed in #36 .)

@YairRand Thanks, I did see that being flipped but assumed that was intentional.
But then I noticed that we don't have explicit code for that indeed. And more importantly, we currently only flip the words "left" and "right" in selectors before a comma.
.foo-left,
.bar-left,
.baz-left { }

This would currently flip foo and bar but not baz. That is indeed a bug, and I agree that the fix should be to not alter the class names.

@YairRand I looked through the individual commits and diffs of #36, but couldn't find a specific diff that would address this. Could you submit a separate PR against current master for that bit?


Color of conditions in Nearby

In the screenshot below, "Exists" is disabled and "Needs Photo" is enabled, right?
I feel that making active thingies grey is not necessary, maybe even counter-intuitive? Same color all the time would be enough I think.
Let's wait for other people's feedback though, maybe it's just me.

Hi,
When does this happen ? I am a new user and I can't find this situation.

I guess part of the reason was that the items in the "Place Type" list are marked in grey when they are selected, so the Place State cards look uniform if they are also greyed when selected. But I am OK either way. :)
@a18jouan are you on beta testing? This feature is only released in beta and alpha.

I agree.
On a related note, the dark text in "Place type" is a bit hard to read against the dark blue background.  Perhaps this could be a lighter grey?  It looks much clearer in this screenshot, but while on my phone I had trouble finding the "X" to close the "place type" drop down menu.

Having used it a bit more now I agree, I think keeping a uniform color is best. If we did keep the colors, I would personally think that "greyed out" means NOT selected (the reverse of what we are currently doing)... but I recall we discussed that and had differing opinions. :)
@mds08011 The dark text is fixed in #3331 , so will probably be out in the next version.

@misaochan Can I work on this issue?

Yes, sure. Assigned to you.


Update sbt-wartremover, wartremover to 3.0.8

Updates

org.wartremover:sbt-wartremover
org.wartremover:wartremover

from 3.0.7 to 3.0.8.
I'll automatically update this PR to resolve conflicts as long as you don't change it yourself.
If you'd like to skip this version, you can just close this PR. If you have any feedback, just mention me in the comments below.
Configure Scala Steward for your repository with a .scala-steward.conf file.
Have a fantastic day writing Scala!

Adjust future updates
Add this to your .scala-steward.conf file to ignore future updates of this dependency:
updates.ignore = [ { groupId = "org.wartremover" } ]

Or, add this to slow down future updates of this dependency:
dependencyOverrides = [{
  pullRequests = { frequency = "@monthly" },
  dependency = { groupId = "org.wartremover" }
}]

labels: library-update, early-semver-patch, semver-spec-patch, commit-count:1

Superseded by #190.


form-control should be 100% when inline form

Normally, I'd expect the input fields to have 100% width rather than the minimum, as this is the default within bootstrap 3 for .form-control fields. Having an inline textarea is not attractive when the textarea is not 100% width. If it needs to be width: auto for popovers, at least have a CSS rule for the inline, ie:
.editable-container.editable-inline
{
display: block;
}
.editable-inline .editableform .form-control
{
width: 100%;
}
Are there scenarios where this doesn't make sense?

I agree.  With inline editing, the dimension constrains are usually part of the rigging around the form control already.
I had to add the following CSS to make my situation look presentable. (textarea inline edting)
.editable-inline .editableform .form-control,
.editable-inline .editableform .control-group
{
width: 100%;
}
.editable-inline .editableform .editable-input {
width: 100%;
padding-right: 85px;
margin-right: -85px;
}

I also agree.  I ended up combining what you guys had and changed the link appearance slightly to use native colors. Also, I had to add some styling to move the editable-clear-x button over:
/* x-editable fix to make 100% wide fields */
.editable-container.editable-inline{
  display: block;
}

.editable-inline .editableform .form-control,
.editable-inline .editableform .control-group
{
  width: 100%;
}
.editable-inline .editableform .editable-input {
  width: 100%;
  padding-right: 85px;
  margin-right: -85px;
}
.editable-clear-x{
  margin-right: 85px;
}
a.editable-click{ color: inherit; }
.editable-empty{ color: inherit; }

The editable-buttons doesn't work with these workarounds. Any ideas? Thanks


Dependency IE compatibility

The is-ua-webview dependency needs to be upgraded to 1.0.1 to support IE9.

I've just had a look, and the package lock dependency is 1.0.1 - so if the dep supports IE9 in this version then it should be working fine? If not, let me know and I'll investigate further.


Add example(s) to Schema

Note: the return Schema(example="<unknown>") is temporary to unblock myself until you or I add register_converter(is_fallback=True).

Codecov Report

Merging #23 (0d014ef) into dev (49bf82e) will decrease coverage by 0.26%.
The diff coverage is 28.57%.

@@            Coverage Diff             @@
##              dev      #23      +/-   ##
==========================================
- Coverage   69.18%   68.92%   -0.27%
==========================================
  Files          16       16
  Lines        1058     1065       +7
  Branches      250      252       +2
==========================================
+ Hits          732      734       +2
- Misses        209      212       +3
- Partials      117      119       +2

Flag
Coverage Δ

unittests
68.92% <28.57%> (-0.27%)
:arrow_down:

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files
Coverage Δ

openapi_builder/builder.py
80.18% <0.00%> (-0.73%)
:arrow_down:

openapi_builder/specification.py
69.77% <33.33%> (-0.33%)
:arrow_down:

Continue to review full report at Codecov.

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


Walker bone transforms are not in sync with the rgb images

CARLA version: 0.9.13
Platform/OS: Windows
Problem you have experienced: I used the code from the examples/draw_skeleton.py to draw the bone positions of pedestrians. The bone positions seems to be out of sync with the rgb images  for pedestrians who are running.

What you expected to happen: Bones in sync with the images.
Steps to reproduce: I am using sync mode with fixed delta secs  and the simulation is replaying a recording.

#!/usr/bin/env python
# Copyright (c) 2021 Computer Vision Center (CVC) at the Universitat Autonoma de
# Barcelona (UAB).
#
# This work is licensed under the terms of the MIT license.
# For a copy, see <https://opensource.org/licenses/MIT>.

import glob
import os
import sys
import math
import argparse
import copy
import time
from multiprocessing import Pool
from PIL import Image

try:
    sys.path.append(glob.glob('../carla/dist/carla-*%d.%d-%s.egg' % (
        sys.version_info.major,
        sys.version_info.minor,
        'win-amd64' if os.name == 'nt' else 'linux-x86_64'))[0])
except IndexError:
    pass

import carla
import random

try:
    import pygame
except ImportError:
    raise RuntimeError('cannot import pygame, make sure pygame package is installed')

try:
    import numpy as np
except ImportError:
    raise RuntimeError('cannot import numpy, make sure numpy package is installed')

try:
    import queue
except ImportError:
    import Queue as queue

class CarlaSyncMode(object):
    """
    Context manager to synchronize output from different sensors. Synchronous
    mode is enabled as long as we are inside this context

        with CarlaSyncMode(world, sensors) as sync_mode:
            while True:
                data = sync_mode.tick(timeout=1.0)

    """

    def __init__(self, world, *sensors, **kwargs):
        self.world = world
        self.sensors = sensors
        self.frame = None
        self.delta_seconds = 1.0 / kwargs.get('fps', 20)
        self._queues = []
        self._settings = None

    def __enter__(self):
        self._settings = self.world.get_settings()
        self.frame = self.world.apply_settings(carla.WorldSettings(
            no_rendering_mode=False,
            synchronous_mode=True,
            fixed_delta_seconds=self.delta_seconds))

        def make_queue(register_event):
            q = queue.Queue()
            register_event(q.put)
            self._queues.append(q)

        make_queue(self.world.on_tick)
        for sensor in self.sensors:
            make_queue(sensor.listen)
        return self
    def tick(self, timeout):
        self.frame = self.world.tick()
        data = [self._retrieve_data(q, timeout) for q in self._queues]
        assert all(x.frame == self.frame for x in data)
        return data

    def __exit__(self, *args, **kwargs):
        self.world.apply_settings(self._settings)

    def _retrieve_data(self, sensor_queue, timeout):
        while True:
            data = sensor_queue.get(timeout=timeout)
            if data.frame == self.frame:
                return data
    # ---------------

def build_projection_matrix(w, h, fov):
    focal = w / (2.0 * np.tan(fov * np.pi / 360.0))
    K = np.identity(3)
    K[0, 0] = K[1, 1] = focal
    K[0, 2] = w / 2.0
    K[1, 2] = h / 2.0
    return K

def get_image_as_array(image):
    array = np.frombuffer(image.raw_data, dtype=np.dtype("uint8"))
    array = np.reshape(array, (image.height, image.width, 4))
    array = array[:, :, :3]
    array = array[:, :, ::-1]
    # make the array writeable doing a deep copy
    array2 = copy.deepcopy(array)
    return array2

def draw_image(surface, array, blend=False):
    image_surface = pygame.surfarray.make_surface(array.swapaxes(0, 1))
    if blend:
        image_surface.set_alpha(100)
    surface.blit(image_surface, (0, 0))

def get_font():
    fonts = [x for x in pygame.font.get_fonts()]
    default_font = 'ubuntumono'
    font = default_font if default_font in fonts else fonts[0]
    font = pygame.font.match_font(font)
    return pygame.font.Font(font, 14)

def get_screen_points(camera, K, image_w, image_h, points3d):

    # get 4x4 matrix to transform points from world to camera coordinates
    world_2_camera = np.array(camera.get_transform().get_inverse_matrix())

    # build the points array in numpy format as (x, y, z, 1) to be operable with a 4x4 matrix
    points_temp = []
    for p in points3d:
        points_temp += [p.x, p.y, p.z, 1]
    points = np.array(points_temp).reshape(-1, 4).T

    # convert world points to camera space
    points_camera = np.dot(world_2_camera, points)

    # New we must change from UE4's coordinate system to an "standard"
    # (x, y ,z) -> (y, -z, x)
    # and we remove the fourth component also
    points = np.array([
        points_camera[1],
        points_camera[2] * -1,
        points_camera[0]])

    # Finally we can use our K matrix to do the actual 3D -> 2D.
    points_2d = np.dot(K, points)

    # normalize the values and transpose
    points_2d = np.array([
        points_2d[0, :] / points_2d[2, :],
        points_2d[1, :] / points_2d[2, :],
        points_2d[2, :]]).T

    return points_2d

def draw_points_on_buffer(buffer, image_w, image_h, points_2d, color, size=4):
    half = int(size / 2)
    # draw each point
    for p in points_2d:
        x = int(p[0])
        y = int(p[1])
        for j in range(y - half, y + half):
            if (j >=0 and j <image_h):
                for i in range(x - half, x + half):
                    if (i >=0 and i <image_w):
                        buffer[j][i][0] = color[0]
                        buffer[j][i][1] = color[1]
                        buffer[j][i][2] = color[2]

def draw_line_on_buffer(buffer, image_w, image_h, points_2d, color, size=4):
  x0 = int(points_2d[0][0])
  y0 = int(points_2d[0][1])
  x1 = int(points_2d[1][0])
  y1 = int(points_2d[1][1])
  dx = abs(x1 - x0)
  if x0 < x1:
    sx = 1
  else:
    sx = -1
  dy = -abs(y1 - y0)
  if y0 < y1:
    sy = 1
  else:
    sy = -1
  err = dx + dy
  while True:
    draw_points_on_buffer(buffer, image_w, image_h, ((x0,y0),), color, size)
    if (x0 == x1 and y0 == y1):
      break
    e2 = 2 * err
    if (e2 >= dy):
      err += dy
      x0 += sx
    if (e2 <= dx):
      err += dx
      y0 += sy

def draw_skeleton(buffer, image_w, image_h, boneIndex, points2d, color, size=4):
    try:
        # draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_root"]], points2d[boneIndex["crl_hips__C"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hips__C"]], points2d[boneIndex["crl_spine__C"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hips__C"]], points2d[boneIndex["crl_thigh__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hips__C"]], points2d[boneIndex["crl_thigh__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_spine__C"]], points2d[boneIndex["crl_spine01__C"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_spine01__C"]], points2d[boneIndex["crl_shoulder__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_spine01__C"]], points2d[boneIndex["crl_neck__C"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_spine01__C"]], points2d[boneIndex["crl_shoulder__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_shoulder__L"]], points2d[boneIndex["crl_arm__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_arm__L"]], points2d[boneIndex["crl_foreArm__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_foreArm__L"]], points2d[boneIndex["crl_hand__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__L"]], points2d[boneIndex["crl_handThumb__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__L"]], points2d[boneIndex["crl_handIndex__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__L"]], points2d[boneIndex["crl_handMiddle__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__L"]], points2d[boneIndex["crl_handRing__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__L"]], points2d[boneIndex["crl_handPinky__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handThumb__L"]], points2d[boneIndex["crl_handThumb01__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handThumb01__L"]], points2d[boneIndex["crl_handThumb02__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handThumb02__L"]], points2d[boneIndex["crl_handThumbEnd__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handIndex__L"]], points2d[boneIndex["crl_handIndex01__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handIndex01__L"]], points2d[boneIndex["crl_handIndex02__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handIndex02__L"]], points2d[boneIndex["crl_handIndexEnd__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handMiddle__L"]], points2d[boneIndex["crl_handMiddle01__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handMiddle01__L"]], points2d[boneIndex["crl_handMiddle02__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handMiddle02__L"]], points2d[boneIndex["crl_handMiddleEnd__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handRing__L"]], points2d[boneIndex["crl_handRing01__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handRing01__L"]], points2d[boneIndex["crl_handRing02__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handRing02__L"]], points2d[boneIndex["crl_handRingEnd__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handPinky__L"]], points2d[boneIndex["crl_handPinky01__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handPinky01__L"]], points2d[boneIndex["crl_handPinky02__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handPinky02__L"]], points2d[boneIndex["crl_handPinkyEnd__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_neck__C"]], points2d[boneIndex["crl_Head__C"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_Head__C"]], points2d[boneIndex["crl_eye__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_Head__C"]], points2d[boneIndex["crl_eye__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_shoulder__R"]], points2d[boneIndex["crl_arm__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_arm__R"]], points2d[boneIndex["crl_foreArm__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_foreArm__R"]], points2d[boneIndex["crl_hand__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__R"]], points2d[boneIndex["crl_handThumb__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__R"]], points2d[boneIndex["crl_handIndex__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__R"]], points2d[boneIndex["crl_handMiddle__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__R"]], points2d[boneIndex["crl_handRing__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_hand__R"]], points2d[boneIndex["crl_handPinky__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handThumb__R"]], points2d[boneIndex["crl_handThumb01__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handThumb01__R"]], points2d[boneIndex["crl_handThumb02__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handThumb02__R"]], points2d[boneIndex["crl_handThumbEnd__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handIndex__R"]], points2d[boneIndex["crl_handIndex01__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handIndex01__R"]], points2d[boneIndex["crl_handIndex02__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handIndex02__R"]], points2d[boneIndex["crl_handIndexEnd__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handMiddle__R"]], points2d[boneIndex["crl_handMiddle01__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handMiddle01__R"]], points2d[boneIndex["crl_handMiddle02__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handMiddle02__R"]], points2d[boneIndex["crl_handMiddleEnd__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handRing__R"]], points2d[boneIndex["crl_handRing01__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handRing01__R"]], points2d[boneIndex["crl_handRing02__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handRing02__R"]], points2d[boneIndex["crl_handRingEnd__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handPinky__R"]], points2d[boneIndex["crl_handPinky01__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handPinky01__R"]], points2d[boneIndex["crl_handPinky02__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_handPinky02__R"]], points2d[boneIndex["crl_handPinkyEnd__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_thigh__R"]], points2d[boneIndex["crl_leg__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_leg__R"]], points2d[boneIndex["crl_foot__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_foot__R"]], points2d[boneIndex["crl_toe__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_toe__R"]], points2d[boneIndex["crl_toeEnd__R"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_thigh__L"]], points2d[boneIndex["crl_leg__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_leg__L"]], points2d[boneIndex["crl_foot__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_foot__L"]], points2d[boneIndex["crl_toe__L"]]), color, size)
        draw_line_on_buffer(buffer, image_w, image_h, (points2d[boneIndex["crl_toe__L"]], points2d[boneIndex["crl_toeEnd__L"]]), color, size)
    except:
        pass

def should_quit():
    for event in pygame.event.get():
        if event.type == pygame.QUIT:
            return True
        elif event.type == pygame.KEYUP:
            if event.key == pygame.K_ESCAPE:
                return True
    return False

def write_image(frame, id, buffer):
    # Save the image using Pillow module.
    img = Image.fromarray(buffer)
    img.save('_out/%s_%06d.png' % (id, frame))

def main():
    argparser = argparse.ArgumentParser(
        description='CARLA Manual Control Client')
    argparser.add_argument(
        '--fov',
        default=60,
        type=int,
        help='FOV for camera')
    argparser.add_argument(
      '--res',
      metavar='WIDTHxHEIGHT',
      # default='1920x1080',
      default='800x600',
      help='window resolution (default: 800x600)')
    args = argparser.parse_args()

    args.width, args.height = [int(x) for x in args.res.split('x')]

    actor_list = []
    pygame.init()

    display = pygame.display.set_mode(
        (args.width, args.height),
        pygame.HWSURFACE | pygame.DOUBLEBUF)
    font = get_font()
    clock = pygame.time.Clock()

    client = carla.Client('localhost', 2000)
    client.set_timeout(5.0)

    world = client.get_world()

    # spawn a camera
    camera_bp = world.get_blueprint_library().find('sensor.camera.rgb')
    camera_bp.set_attribute("image_size_x", str(args.width))
    camera_bp.set_attribute("image_size_y", str(args.height))
    camera_bp.set_attribute("fov", str(args.fov))
    camera = world.spawn_actor(camera_bp, carla.Transform())

    # spawn a pedestrian
    world.set_pedestrians_seed(0)
    ped_bp = random.choice(world.get_blueprint_library().filter("walker.pedestrian.*"))
    print(f"ped_bp: {ped_bp}")
    trans =  carla.Transform()
    trans.location = world.get_random_location_from_navigation()

    print(trans)
    # trans.location = world.get_random_location_from_navigation()
    ped = world.spawn_actor(ped_bp, trans)
    walker_controller_bp = world.get_blueprint_library().find('controller.ai.walker')
    controller = world.spawn_actor(walker_controller_bp, carla.Transform(), ped)
    controller.start()
    controller.go_to_location(trans.location)
    controller.set_max_speed(10.0)

    # keep tracking of actors to remove
    actor_list.append(camera)
    actor_list.append(ped)
    actor_list.append(controller)

    # get some attributes from the camera
    image_w = camera_bp.get_attribute("image_size_x").as_int()
    image_h = camera_bp.get_attribute("image_size_y").as_int()
    fov = camera_bp.get_attribute("fov").as_float()

    try:
        pool = Pool(processes=5)
        # Create a synchronous mode context.
        with CarlaSyncMode(world, camera, fps=30) as sync_mode:

            # set the projection matrix
            K = build_projection_matrix(image_w, image_h, fov)

            blending = 0
            turning = 0
            while True:
                if should_quit():
                    return
                clock.tick()

                # make some transition from custom pose to animation
                ped.blend_pose(0)

                # move the pedestrian
                blending += 0.015
                turning += 0.009

                # move camera around
                trans = ped.get_transform()
                x = math.cos(turning) * -3
                y = math.sin(turning) * 3
                trans.location.x += x
                trans.location.y += y
                trans.location.z = 2
                trans.rotation.pitch = -16
                trans.rotation.roll = 0
                trans.rotation.yaw = -360 * (turning/(math.pi*2))
                camera.set_transform(trans)

                # Advance the simulation and wait for the data.
                snapshot, image_rgb = sync_mode.tick(timeout=5.0)

                # Draw the display.
                buffer = get_image_as_array(image_rgb)

                # get the pedestrian bones
                bones = ped.get_bones()

                # prepare the bones (get name and world position)
                boneIndex = {}
                points = []
                for i, bone in enumerate(bones.bone_transforms):
                    boneIndex[bone.name] = i
                    points.append(bone.world.location)

                # project the 3d points to 2d screen
                points2d = get_screen_points(camera, K, image_w, image_h, points)

                # draw the skeleton lines
                draw_skeleton(buffer, image_w, image_h, boneIndex, points2d, (0, 255, 0), 2)

                # draw the bone points
                draw_points_on_buffer(buffer, image_w, image_h, points2d[1:], (255, 0, 0), 4)

                draw_image(display, buffer)
                # pool.apply_async(write_image, (snapshot.frame, "ped", buffer))

                # display.blit(font.render('%d bones' % len(points), True, (255, 255, 255)), (8, 10))

                pygame.display.flip()
                time.sleep(0.1)

    finally:
        # time.sleep(5)
        print('destroying actors.')
        for actor in actor_list:
            actor.destroy()
        pygame.quit()
        pool.close()
        print('done.')

if __name__ == '__main__':

    try:

        main()

    except KeyboardInterrupt:
        print('\nCancelled by user. Bye!')

Hi, i also encounter some issues when drawing the skeletons into recordings...
I replayed a file and took a screenshot of the spectator at a certain frame which looks like this:

Note: Screenshot is taken with a screen saving tool since i do not now a CARLA method to get the spectator output...
A rgb camera I placed in the scene (at the same position as the spectator) gives me this result:

Drawing the bones into the rgb image (same frame) looks like this:

Let's take a closer look at the left walker in the three pictures.
Here again the three scenes but only containing the part I want to focus on:
spectator:

rgb:

rgb with bones:

When looking at the images closely there are a few things to notice:

The walkers contains some artifacts in the rgb image compared to the spectator screenshot
The walker on the rgb image seems to have a slight rotation compared to the one captured with the spectator. Let's look closely on the left foot. One can see, that on the spectator image the foot is slightly touching the next crosswalk stripe. On the rgb image this is not the case (because of some rotation I guess).
These issues are already partly mentioned in https://github.com/carla-simulator/carla/issues/4975
Interestingly, this issue also persists when drawing the skeletons into the rgb image, causing them them to not align properly. If we look at the skeleton on the third image we can see that it is indeed above the next stripe of the crosswalk (as the spectator screenshot suggests), but does (of course) not match up with the walkers feet on the rgb image...

Therefore I think that the bone positions seem to be correct, but the walker displayed in the rgb image is not...
@uservinu are you only encountering this issue for running pedestrians, or for all walkers in replayed files as i do?

@ptr-br  I have the issue for all pedestrians, just the issue is very bad for running pedestrians.


[Libs] ParAlmond and libs updates

Large PR started over the long weekend. Here's the rundown:

ParAlmond code cleanup. The parAlmond source naming and structure now matches the reset of the repo. It uses the linearSolver and linAlg modules for some operations which reduces the lib size.
PGMRES LinearSolver. Extracted from parAlmond, moved to libs.
OAS precon re-enabled. Still somewhat experimental, but it's been added to unit tests as well.
Removing usage of Platform comm. The MPI_Comm in the platform is the 'global' comm on which the whole app is initialized. Modules like the mesh, timeSteppers, linearSolvers, etc., can be made on sub-communicators so I've removed usage of the platform comm everywhere necessary.
BLAS interface cleanup Just some clean up for interfacing to BLAS/LaPack and made it consistent throughout.

This PR is the first step for several ParAlmond improvements in the pipeline.

Cool to note that the last three bug fix commits were found using the unit tests. Very glad we added that.

LGTM.
Does the AMG setup source need to be in a separate subdirectory ?

Nope, just left it that way and can easily move it. Do you prefer it all in the /libs/parAlmond/ directory for consistency?

I think that is more consistent. Previously I had to think about which directory when looking...

Will update, test, then merge.

Sounds good.
I think the new improvements help readability.
Also the coverage seems to be up at 83+%


what is the Event that trigger when an app is add by user

What is the event which triggers when this slack bot app is added,
For example; when a user add my app I want to have an API call to happen which gives an entry in DB
How do I achieve this?
Like for every 24 hours, I want to know which all the user have installed my app, to all that users I want to send a notification this my use case

Hey @vvvprabhakar,
Are you talking about the app being installed to a workspace? Or a specific user authing against an app? Or when an app gets added to a channel?
Usually, for saving a token to the DB, you would do this during the OAuth flow. So slack would send a payload to your OAuth redirect and at that moment you would save the installation related fields to your DB.

I want to send a notification to the user who all installed the app in my workspace (i cannot send to all the people )
I want the userId of the users who all installed my app
Like for suppose if I click +button add the app
Is there any event for it ??

@vvvprabhakar If you're using Bolt for JS along with its OAuth flow support, you can access an installer's user ID in callbackOptions.success handler. The argument installation has user.id and the ID is the installer's Slack user ID.
https://slack.dev/bolt-js/concepts#authenticating-oauth

How do I send message to all the people in my workspace ??

Do you mean sending DMs to all users in a workspace? From a user experience perspective, we don’t recommend doing so but technically you can get a list of user IDs by calling users.list API method with pagination, opening a DM with each user by calling conversations.open, and sending a DM using chat.postMessage API.
It seems we’ve already provided an answer to your original question. Can we close this question issue now?

Is there a query option to check who all installed my app in my workspace ??
What is the event on when the user open the app is it app:home

Unfortunately, there is no api to fetch the list of the users that installed your app. Your app needs to store user data in your database when completing an OAuth flow.
app_home _opened events are triggered when your app users access home tab or DM with your app’s bot user.


feat: support encryption on first boot

I have copied/modified mender_luks_encrypt_part in mender-luks-init.sh.
If you recommend so, I could attempt to make this function part of mender-luks-util.sh and attempt to make the same logic used in mender-luks-encrypt-image.sh. But personally I would argue against it in this case, and would prefer copying the code as it is small and on boot we are very restricted so there is meaningful difference now (and perhaps more for future changes).
If you also want to, I could later make another PR to change mender-luks-encrypt-image.sh to be interruptible and repeatable same as with the boot, which would fix 15

If you recommend so, I could attempt to make this function part of mender-luks-util.sh and attempt to make the same logic used in mender-luks-encrypt-image.sh.

I think what you've done here is fine. Not worth doing anything to mender-luks-util.sh or mender-luks-encrypt-image.sh.

If you also want to, I could later make another PR to change mender-luks-encrypt-image.sh to be interruptible and repeatable same as with the boot, which would fix 15

I think that's a good idea (but the priority (IMO) is low).


[main] Update community files

Cron -knative-prow-robot
/cc knative-sandbox/autoscaling-wg-leads
/assign knative-sandbox/autoscaling-wg-leads
Produced by: knative-sandbox/knobots/actions/update-community
Details:

/cancel lgtm
/cancel approve

/lgtm cancel
/approve cancel


Feature Request: add force flag when importing / changing a rule

Hi, it would be convenient to have a -Force update flag in case a rule setting was changed. Current behavior asks for confirmation to the end user. However this limits the automation of using this module in CI pipelines.
Same comment for the other type of settings (e.g. hunting queries), a Force flag would be useful

hi @sbroosnokia thanks for your feedback, this is actually already implemented in all the functions, you can use "-Confirm:$false" switch to skip the confirm question. please let me know if this is not working for you.

Ah thanks! I misinterpreted this flag. I thought it always forced confirmation, even if nothing was changed. Issue can be closed


Integration Test - Release - 2022/03/11 11:20:04

Auto create for integration test. IssueCommandFlow

#pri1

Just type '#pri3'

#pri2

#pri3

#assign PRMergerTest1

#assign NonAllowedUser

The following users don't have valid GitHub IDs, or are not collaborators on this repo: nonalloweduser

#reassign PRMergerTest2

#reassign NonAllowedUser

#please-close

The following users don't have valid GitHub IDs, or are not collaborators on this repo: nonalloweduser

#unassign PRMergerTest1

GitHub user PRMergerTest2 has been removed from the MicrosoftDocs organization, so they were automatically removed as an assignee.

#unassign NonAllowedUser


Can environment variables be used to configure the server?

I only see CERBOS_NO_TELEMETRY. Is it possible to configure the storage and other values using environment variables?

Yes you can configure configuration value as an environment variable using

Config values can reference environment variables by enclosing them between ${}, for example ${HOME}. Defaults can be set using ${VAR:default}.

https://docs.cerbos.dev/cerbos/latest/configuration/index.html


Decide whether PhasedXPowGate(0) == X

Deferred from https://github.com/quantumlib/Cirq/pull/1788

I do like the idea of having the concept of "equivalent in the eyes of QC", but the == operator may not be suited for that purpose. If we special case instances like this and get used to the idea that a==b implies a and b are equivalent in the eyes of QC, then it can be easy for a user to make the mistake of thinking that a and b are equivalent in the eyes of QC implies a==b.
Suppose instead we add a protocol to serve this purpose? Global phases should be ignored for the purpose of such a protocol since they aren't physically meaningful in QC.  We already have a test in testing that checks this for circuits with terminal measurements.

While I was vehemently opposed to having PhasedXPowGate.new sometimes give you an X, I'm fine with saying they're equal. This all reminds me of the difference between e.g. float and int
It would be surprising if float(3) gave you an int but it's not surprising that float(3) == int(3)

One of my primary issues with the == relationship is that you might have an instance where a device supports only one of XPowGate and PhasedXPowGate, in which case the device may support XPowGate but not understand PhasedXPowGate. My intuition says that A==B implies Device.validate_gate(A) and Device.validate_gate(B) either both pass or both throw errors.

I'm not sure if I personally would expect that implication, but I don't have a convincing argument.
How should we resolve this issue? anyone else have thoughts?

Current behavior is still as described
g = cirq.PhasedXPowGate(exponent=1, phase_exponent=0)
h = cirq.X
g == h

Ultimately this is somewhat tied to concepts of a gate set, however I don't see a good case not to keep them equal since it really only occurs now for specific defined values of the gates where they are equal.
I'm going to close as we have other places where gate set is argued for and against.
We should open if there are places where this causes user confusion or our own bad code.


add sap hana support for sql chains and agents

Added support for SAP HANA databases for SqlDatabaseChain and SqlToolkit.
Main elements:

added 'sap' as supported database (= typeorm database type name)
correct SQL generation to use schema name
added instruction to only query using schema name in prompts
added 2 examples

This requires @sap/hana-client and hdb-pool dependencies which I added to the examples package.json but not the main package.json.
Database-specific coding seems to have been there for SqlDatabaseChain but not for SqlToolkit. See also #2208

Thanks for this! Looks good overall - one question!

Please see changes in new commit. Thanks!

Looks good, one more comment!

Ok, dependencies removed.

Just lint + format + expose an example - thank you!
If you have time to get some of those other agent changes in, we'd welcome it as well :)


Support modularized JVM applications (multi-project) in Gradle init

This PR adds support for generating additional library subprojects with convention plugins in buildSrc when initialising an application via gradle init. This is now supported for all JVM languages. To get there, this PR restructured the way the init descriptors are setup for different JVM languages to remove duplication and to avoid adding more duplication.
The example source code is based on the multi-project samples from the :docs project (to eventually replace those completely).
This setup currently only supports Junit5 as testing framework for any JVM language which is probably fine.
Follow ups to be done in separate PRs:

Add release note section
Generate samples with readme based on this (extending what was done in #14291)

Review can be done commit-by-commit.

What does "modularize" mean? That the application is composed from jigsaw modules? or that the application is composed from some libraries (but which are not jigsaw modules)?

It looks like the intent is the later - that the application is composed of a main entry point project and some additional libraries. I would not call this "modularization" as this term is ambiguous and/or misleading. I would simply model this as "adding some libraries to the application" and keep it concrete.

Thanks for the suggestion @adammurdoch. I wasn't happy with just "modularize" either.
The intention is for now to add 'JVM library' projects. But we might add another option to the choice here in the future for 'Java Modules' (Jigsaw).

@bot-gradle test this

@bot-gradle test this

OK, I've already cancelled the old build and triggered a new ReadyForMerge build for you.

@bot-gradle test this

Sorry some internal error occurs, please contact the administrator @blindpirate

@bot-gradle test this

@bot-gradle test this

OK, I've already triggered ReadyForMerge build for you.

@bot-gradle test this

OK, I've already triggered ReadyForMerge build for you.

@bot-gradle test this

OK, I've already triggered ReadyForMerge build for you.

@bot-gradle test QF

OK, I've already triggered QuickFeedback build for you.

@bot-gradle test QF

OK, I've already cancelled the old build and triggered a new QuickFeedback build for you.

@bot-gradle test QF

OK, I've already triggered QuickFeedback build for you.

@bot-gradle test QF

OK, I've already cancelled the old build and triggered a new QuickFeedback build for you.

@bot-gradle test QF

OK, I've already cancelled the old build and triggered a new QuickFeedback build for you.

@bot-gradle test BD

Sorry I don't understand what you said, please type @bot-gradle help to get help.

@bot-gradle test QF

OK, I've already triggered QuickFeedback build for you.

@bot-gradle test this

OK, I've already triggered ReadyForMerge build for you.


fix: ensures the right default node version is set

Pull Request Template
📲 What

fix: ensures the right default node version is set

🤔 Why
Node was defaulting to the first in the array which is now the v18, whereas v20 should be the default within pwsh (working in bash)
🛠 How
👀 Evidence
🕵 How to test

/azp run


Vectorization with emcee solver

Emcee allows for vectorized calls to the log-likelihood function by setting vectorize=True in the EnsembleSampler. With this option enabled, the input to the log-likelihood function is a 2D array of theta values of size (n_walkers x n_theta). Doing this in probeye results in an error in check_parameter_domains (see minimal example below).
Having this functionality could be useful for:

Parallelizing MCMC with a computationally expensive forward model, e.g. using offloading.
Faster inference with cheap surrogate models that accept vectorized inputs.

A minimal example based on the linear regression integration test:
import numpy as np
from probeye.definition.inverse_problem import InverseProblem
from probeye.definition.forward_model import ForwardModelBase
from probeye.definition.sensor import Sensor
from probeye.definition.likelihood_model import GaussianLikelihoodModel
from probeye.inference.emcee.solver import EmceeSolver

# ============================================================================ #
#                              Set numeric values                              #
# ============================================================================ #
# Options
n_steps = 200
n_initial_steps = 100
n_walkers = 20

# 'true' value of a, and its normal prior parameters
a_true = 2.5
mean_a = 2.0
std_a = 1.0

# 'true' value of b, and its normal prior parameters
b_true = 1.7
mean_b = 1.0
std_b = 1.0

# 'true' value of additive error sd, and its uniform prior parameters
sigma = 0.5
low_sigma = 0.0
high_sigma = 0.8

# the number of generated experiment_names and seed for random numbers
n_tests = 50
seed = 1

# ============================================================================ #
#                           Define the Forward Model                           #
# ============================================================================ #

class LinearModel(ForwardModelBase):
    def interface(self):
        self.parameters = [{"a": "m"}, "b"]
        self.input_sensors = Sensor("x")
        self.output_sensors = Sensor("y", std_model="sigma")

    def response(self, inp: dict) -> dict:
        # this method *must* be provided by the user
        x = inp["x"]
        m = inp["m"]
        b = inp["b"]
        return {"y": m * x + b}

    def jacobian(self, inp: dict) -> dict:
        x = inp["x"]  # vector
        one = np.ones((len(x), 1))
        return {"y": {"x": None, "m": x.reshape(-1, 1), "b": one}}

# ============================================================================ #
#                         Define the Inference Problem                         #
# ============================================================================ #
problem = InverseProblem("Linear regression (AME)")

problem.add_parameter(
    "a",
    "model",
    tex="$a$",
    info="Slope of the graph",
    prior=("normal", {"mean": mean_a, "std": std_a}),
)
problem.add_parameter(
    "b",
    "model",
    info="Intersection of graph with y-axis",
    tex="$b$",
    prior=("normal", {"mean": mean_b, "std": std_b}),
)
problem.add_parameter(
    "sigma",
    "likelihood",
    domain="(0, +oo)",
    tex=r"$\sigma$",
    info="Standard deviation, of zero-mean additive model error",
    prior=("uniform", {"low": low_sigma, "high": high_sigma}),
)

# add the forward model to the problem
linear_model = LinearModel("LinearModel")
problem.add_forward_model(linear_model)

# ============================================================================ #
#                    Add test data to the Inference Problem                    #
# ============================================================================ #
# data-generation; normal likelihood with constant variance around each point
np.random.seed(seed)
x_test = np.linspace(0.0, 1.0, n_tests)
y_true = linear_model.response(
    {linear_model.input_sensor.name: x_test, "m": a_true, "b": b_true}
)[linear_model.output_sensor.name]
y_test = np.random.normal(loc=y_true, scale=sigma)

# add the experimental data
problem.add_experiment(
    f"TestSeries_1",
    fwd_model_name="LinearModel",
    sensor_values={
        linear_model.input_sensor.name: x_test,
        linear_model.output_sensor.name: y_test,
    },
)

# ============================================================================ #
#                           Add likelihood model(s)                            #
# ============================================================================ #
# add the likelihood model to the problem
problem.add_likelihood_model(
    GaussianLikelihoodModel(
        prms_def="sigma",
        experiment_name="TestSeries_1",
        model_error="additive",
        name="SimpleLikelihoodModel",
    )
)

# ============================================================================ #
#                    Solve problem with inference engine(s)                    #
# ============================================================================ #
emcee_solver = EmceeSolver(
    problem,
    show_progress=True,
)

inference_data = emcee_solver.run_mcmc(
    n_walkers=n_walkers,
    n_steps=n_steps,
    n_initial_steps=n_initial_steps,
    vectorize=True
)

I looked into this, and I saw that there are quite a few changes necessary in order to make this feature possible. But I also think the code will get more complicated, because there will be much more ifs and for-loops in a lot of methods and function. So, it is possible, but at the cost of additional code complexity. If there is not an urgent need, I would not implement this at the moment.


Gitlab integration Problem with target_project_id not found

https://github.com/dependabot/dependabot-core/blob/5d94313a255299144fd3c597708f9b80080f72f5/common/lib/dependabot/pull_request_creator.rb#L297
I think you forgott the default value for the fetch.
Because gitlab produces error:
/home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/dependabot-common-0.240.0/lib/dependabot/pull_request_creator.rb:297:in fetch': key not found: :target_project_id (KeyError) 10:01:10  	from /home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/dependabot-common-0.240.0/lib/dependabot/pull_request_creator.rb:297:in gitlab_creator'
10:01:10  	from /home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/sorbet-runtime-0.5.11193/lib/types/private/methods/call_validation.rb:272:in bind_call' 10:01:10  	from /home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/sorbet-runtime-0.5.11193/lib/types/private/methods/call_validation.rb:272:in validate_call'
10:01:10  	from /home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/sorbet-runtime-0.5.11193/lib/types/private/methods/_methods.rb:272:in block in _on_method_added' 10:01:10  	from /home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/dependabot-common-0.240.0/lib/dependabot/pull_request_creator.rb:234:in create'
10:01:10  	from /home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/sorbet-runtime-0.5.11193/lib/types/private/methods/call_validation.rb:272:in bind_call' 10:01:10  	from /home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/sorbet-runtime-0.5.11193/lib/types/private/methods/call_validation.rb:272:in validate_call'
10:01:10  	from /home/dependabot/dependabot-script/vendor/ruby/3.2.0/gems/sorbet-runtime-0.5.11193/lib/types/private/methods/_methods.rb:272:in block in _on_method_added' 10:01:10  	from ./dependabot-script.rb:235:in block (2 levels) in '
10:01:10  	from ./dependabot-script.rb:158:in each' 10:01:10  	from ./dependabot-script.rb:158:in block in '
10:01:10  	from ./dependabot-script.rb:101:in each' 10:01:10  	from ./dependabot-script.rb:101:in '

Tagging @andrcuns


Create Signup Page

Make Signup Page with similar concepts from Login Page, but with Fields for First and Last name, or Username, or any other necessary user information.

I will mock this and the search page up so that we are ahead of the game and ready to actually code!


Improve type inference on parameter types and return types of overload class methods implementation.

Suggestion

🔍 Search Terms

class\implements\type inference\overload\class methods
✅ Viability Checklist

My suggestion meets these guidelines:

[] This wouldn't be a breaking change in existing TypeScript/JavaScript code
[*] This wouldn't change the runtime behavior of existing JavaScript code
[*] This could be implemented without emitting different JS based on the types of the expressions
[*] This isn't a runtime feature (e.g. library functionality, non-ECMAScript syntax with JavaScript output, new syntax sugar for JS, etc.)
[*] This feature would agree with the rest of TypeScript's Design Goals.

⭐ Suggestion

Read the codes and comments below.
📃 Motivating Example

class Foo {
    foo(a: number): 1;
    foo(a: string): 2;
    foo(a: boolean): 3;
    foo(a: boolean | number | string): 1 | 2 | 3 {
        if (typeof a === 'number') return 1;
        if (typeof a === 'string') return 2;
        return 3;
    }
}

interface IFoo {
    foo<T extends 1>(a: number): T;
    foo<T extends 2>(a: string): T;
    foo<T extends 3>(a: boolean): T;
}

type F = {
    <T extends 1>(a: number): T;
    <T extends 2>(a: string): T;
    <T extends 3>(a: boolean): T;
}

class Bar2 implements IFoo {
    foo(a) { // error here: ts 7006. expected to be number | string | boolean
        if (typeof a === 'number') return 1;
        if (typeof a === 'string') return 2;
        return 3;
    }
}

class Bar implements IFoo {
    foo(a: number | string | boolean) {
        if (typeof a === 'number') return 1;
        else if (typeof a === 'string') return 2;
        else return 3;
    }
}

class Baz {
    foo: F = (a: any) => {
        if (typeof a === 'number') return 1;
        if (typeof a === 'string') return 2;
        return 3;
    }
}

new Foo().foo(1); // infer as 1
new Baz().foo('1'); // infer as 2;
new Bar().foo(true) // infer as 1 | 2 | 3, expected to be 3;

💻 Use Cases

Some request/fetch library, return specific type based on path or parameters.
Maybe releated to https://github.com/microsoft/TypeScript/issues/14107 https://github.com/microsoft/TypeScript/issues/22609 https://github.com/microsoft/TypeScript/issues/28172 https://github.com/microsoft/TypeScript/issues/25352 https://github.com/microsoft/TypeScript/issues/14515

Playground link...


Summarize map view stats when attempting to delete a map

@saleiva commented on Wed Nov 09 2016
https://github.com/CartoDB/cartodb/issues/10664

@arianaescobar commented on Wed Nov 23 2016
@saleiva at this stage maybe?

@arianaescobar commented on Wed Nov 23 2016
Also, besides map views and likes, is there any other stat we can/want to give?

@saleiva commented on Wed Nov 23 2016
Yep, but that's not the last version of the modal. Try to delete from inside a map to see the last version

@arianaescobar commented on Wed Nov 23 2016
This is what I propose:

tagging @brittanymicek @vuxita for copy review

@saleiva commented on Wed Nov 23 2016
Total map views are not so relevant, since a map that was very popular 2 years ago can be irrelevant now. ( I imagine the poor map sitting alone in the middle of nowhere in the deep web).
Why don't we use icons for illustrating likes and mapviews? I just love ❤ s

@brittanymicek commented on Thu Nov 24 2016
Hola @arianaescobar !
Here is some updated copy! Let me know what you think/questions!
Are you sure you want to delete: "Populated places on Earth"?[1]
This map was created on May 6, 1987 and has 4,670 views, 35 likes, and 0 shares. [2]
NOTE: You can export {name of map} as a .CARTO file to {reason they might want to export the viz}. Once your map is deleted it cannot be recovered. Please be sure before proceeding. [3]
[CANCEL] [YES, DELETE]

This question should lead and be in the largest font. It allows the user to skip reading the remaining content that is not necessarily relevant (since they have decided to delete the map and the below copy is just informational). Additionally, the question corresponds with the answer options of: CANCEL and YES, DELETE.

Providing the sharing stat might be useful information in helping a user decide whether or not to delete their map. Maybe they want to share this map but hadn't considered it or maybe despite the amount of views the map still wasn't shared or was shared quite a bit. Additionally, adding a date of creation or a time estimate ("This map is 6 months young") might be a helpful stat.

To @saleiva 's suggestion - icons: creation: a calendar or clock; views: eyeball; likes: heart; shares: recycle symbol. I'm sure you'll think of cooler ones! ;)

I am not sure what the point of telling them that they can export the map as a .CARTO file is. Why would someone be at this stage and want to export their map as a .CARTO file? Are we assuming they are deleting the viz for more space and exporting the map will allow them to save the viz in some way? Also this is important information and should be higher positioned as well as the same font as the rest of the copy in the body.

xoB

@arianaescobar commented on Thu Nov 24 2016
Thank you @brittanymicek!!
A few comments:

In case we'd like to add a date, I would suggest adding when it was last updated rather than when it was created. I think it has more value than the creation date. @saleiva thoughts?

If we have the information about shares (which I think Luis has), I don't see why not adding it. Although let's be careful on when so much information it's too much information.

I'm worried that with those changes we're delegating the most key sentence to the end "once is deleted, it cannot be recovered" and that might led to more people not reading it and the trouble that could create.

About why adding the option to export the map: it's a form of backup. You might wan't to delete your map, but exporting the .CARTO file you'll have a backup in case you wan't to recover it in the future. In my humble opinion, I don't think this is more important than the following sentence and I don't think we should change the order of the message.

@arianaescobar commented on Thu Nov 24 2016
@saleiva how about "recent map views", is there such a thing?
I'll add some icons! :)

@saleiva commented on Thu Nov 24 2016
Map views in the last XX days?

@arianaescobar commented on Thu Nov 24 2016
Feedback applied:

@saleiva commented on Thu Nov 24 2016
Number of shares will be challenging. I´d remove it and close and promote.

@arianaescobar commented on Fri Nov 25 2016

Love it

+1 Thank you @arianaescobar !!! <3
One thing (copy edit/fix):
"Before deleting your map, you can export it as a .CARTO file."*

add "it", "a", and a full stop (.)

xoB

Still valid


visualization function for Examine tasks

Adds a visualization function for Examine tasks, visualizes canonical coordinates (under the env variable VISUALIZE_EXAMINE)
Stack from ghstack:

#911
#909
#900
#861
#860
#859
#858
#857
-> #856
#855
#854

stack merged in #910


Literature

Relevant literature...

Can massless particles be charged? http://journals.aps.org/pr/abstract/10.1103/PhysRev.125.1055

The massless equation (without the electromagnetic gauge field) seems to have been proposed first by N. D. Sen Gupta in 1967 in a paper entitled "The Wave Equation For Zero Rest-Mass Particles." Since then, many have discussed this equation. Recently, Valeriy V. Dvoeglazov discussed this equation in AACA and cites a range of literature on the equation.
Gupta identified the momentum term of $p_0$ with an additional mass term. Interestingly, Gupta suggests the even and odd fields can be coupled via a duality gauge field. Thus far, I have seen no identification of the zitter behavior. A review of this literature will be worthwhile.
There may be disagreement with regard to the symmetries of this pair of equations. I thought that charge and time reversal symmetries would be violated, but recently reversed that opinion.

http://www.emph.com.ua/9/pdf/raspini.pdf


Falco plugin for GitLab

What type of PR is this?

Uncomment one (or more) /kind <> lines:

/kind bug

/kind cleanup

/kind design

/kind documentation

/kind failing-test

/kind feature

Any specific area of the project related to this PR?

Uncomment one (or more) /area <> lines:

/area plugins

/area registry

/area build

/area documentation

What this PR does / why we need it:
Which issue(s) this PR fixes:

Fixes #
Special notes for your reviewer:

[APPROVALNOTIFIER] This PR is NOT APPROVED
This pull-request has been approved by: an1245
Once this PR has been reviewed and has the lgtm label, please assign mstemm for approval. For more information see the Kubernetes Code Review Process.
The full list of commands accepted by this bot can be found here.

Needs approval from an approver in each of these files:

OWNERS

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

LGTM label has been added.  Git tree hash: b24b372488697df7d2b4bd38adff3cc77bde534a

[APPROVALNOTIFIER] This PR is APPROVED
This pull-request has been approved by: an1245, leogr
The full list of commands accepted by this bot can be found here.
The pull request process is described here

Needs approval from an approver in each of these files:

OWNERS [leogr]

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment


Cannot make it work

After installing the package I'm getting this error
 ERROR  Failed to compile with 2 errors                                                                                11:03:17 AM

This dependency was not found:

* vue-draggable-resizable in ./src/main.js, ./~/babel-loader/lib!./~/vue-loader/lib/selector.js?type=script&index=0!./src/components/Home.vue

To install it, you can run: npm install --save vue-draggable-resizable

The package name is present in package.json ("vue-draggable-resizable": "1.0.0",) as well as stored under node_modules
Vue version is 2.3.3
Node evrsion v6.1.0
It seems there is no dist folder:

Sorry @ecerroni I missed the .npmignore file, so the package did not get fully published on npm. You can try now with version 1.0.1.

Now it works :) Thanks!


consider alternative tools for package development?

namely tools used in this cookiecutter project:
https://cookiecutter-hypermodern-python.readthedocs.io/en/2021.4.15/
which is very opinionated.
I'm not advocating for or against any particular tools--mainly raising an issue to save the link.
And hopefully the issue reminds us to reconsider for future dev.

totally @NickleDave are you suggesting that we consider / reconsider our cookie cutter to reflect that one? i agree that this one definitely needs a good bit of work. i have this thought of pulling together a really nice guide that points to our cookie cutter and references relevant chapters in @ttimbers textbook as it makes sense on topics such as CI, etc.

Friends, I'm closing all of the open issues, given that we have a complete redo of the template now! 🚀! Thank you all for this discussion!! Please reopen this if I'm closing it in error.


Added max level prop to Automator

Took the methods and fields from the generator class, and modified the Automator so that it can have a max level. and up to the max value of a long like in the Generator.

I'm incorporating this into a JavaFX project, and thought it would be nice to be able to set a max level to the Automators as well, and I couldn't find a way to do so, so that's where this came about :)

and I just realized that there is a libclicker2.
is this feature already in that?


I consider redoing this for other languages, is this possible for a private person?

I would love to recrate this experiment in German and maybe also Esperanto and it looks easy enough, I bascially just have to adapt prompt.txt to another language and follow the rest of the instructions, right?
I am willing to invest arount 100€ into this, do you think it could be feasible? I don't care if the training is slow or if I need a few months for it. So do you see more ways to optimize the process? For example could I train it on Google Colab?

This project created a Portuguese version for $8 simply by translating the instruction following dataset: https://github.com/22-hours/cabrita/blob/main/README.md. Assuming similar translation costs for German, it sounds feasible to me. As for training, the LoRa version of Alpaca can be trained quickly in Google Colab for free.

Yes, I will document my experiments in the readme of this repo: https://github.com/stefangrotz/alman-alpaca
Anyone is welcome to participate.

We're training models on German instructions over here: https://github.com/Whadup/llamarr_alpaca/

Great, than I'll join you and delete my repo.

This is just the JSON standard way of storing unicode. If you load it with python, you'll get nice unicode text.
You could also store it as unicode-json with json.dump(data, file, ensure_ascii=False)

Good to know :)
I have a few ideas about creating adidtional training data in German using Wikidata, Wikipedia, Wikihow and advanced GPT-4 prompts. Can I just join the discussion on your reopo for this?

@Whadup I just started the training of my first model using the translation from your repo. Thanks for sharing it, I plan to share my model in the coming days.
I plan to translate https://github.com/gururise/AlpacaDataCleaned into German, but it might be worth waiting a few weeks, since people are still cleaning up the dataset in this repo.

Hi,
yeah I wasn't sure about how to share the model, but if you send me a PM I think I could share my checkpoint.
Using the cleaned dataset sounds good, I still have my deepl-script for translating.
btw, translating with deepl destroys all tasks of the form "fix the spelling/grammar/style of the following input.", as deepl already fixes everything in the input. So I guess this needs manual work after all


Do we plan to support entity annotation?

Sometime an entity such as person name, or address may across two lines but not fully contains the tokens of the covered line. Similar things applies to a sentence annotation. For example,  currently I find no way to annotate the sentence inside the red line area. Thank you for your answers.

I believe there's a mechanism for relating annotations that might capture your intent here.
@DeNeutoy @lolipopshock Do either of you have any ideas here?


fix(network): fix the mapping of all events and board elections to Locals

Also updates the logic of what tag to display for what criterion, making the code nicer, and removing some errors that were still in there (for instance that the membership list could not display exceptions)

:tada: This PR is included in version 1.37.5 :tada:
The release is available on GitHub release
Your semantic-release bot :package::rocket:


Can't download pretrained model and dataset

Hi. How can i download your dataset and pretrained model?

same query, is there any update on this? thank you

http://zefirus.org/datasets/models/ThermalGAN/ThermalGAN.pth

http://zefirus.org/datasets/models/ThermalGAN/ThermalGAN.pth

Thanks. I was able to download weights!

This link is still showing Page not Found.

http://zefirus.org/datasets/models/ThermalGAN/ThermalGAN.pth

sorry, the page is not found.Can you share the pre-train model?

@xevolesi Hi,could you provide the  pre-trained model? This link is still showing Page not Found.

http://zefirus.org/datasets/models/ThermalGAN/ThermalGAN.pth

Thanks. I was able to download weights!

hi. sorry to bother you, the weight is not avalible in this link, can i get the weight you downloaded? my email is<EMAIL_ADDRESS>thanks a lot

@xevolesi  hi. sorry to bother you, the weight is not avalible in this link, can i get the weight you downloaded? my email is<EMAIL_ADDRESS>thanks a lot

@xevolesi hi. sorry to bother you, the weight is not avalible in this link, can i get the weight you downloaded? my email is<EMAIL_ADDRESS>thanks a lot

@WeiBrown Hello, I'm in need of the ThermalGAN.pth weights for a research project and was wondering if you might be able to share them with me. If you have the file and are willing to share, could you please send it to<EMAIL_ADDRESS>

@legendary111 Hello, I'm in need of the ThermalGAN.pth weights for a research project and was wondering if you might be able to share them with me. If you have the file and are willing to share, could you please send it to<EMAIL_ADDRESS>

@Maxlium Hello, I'm in need of the ThermalGAN.pth weights for a research project and was wondering if you might be able to share them with me. If you have the file and are willing to share, could you please send it to<EMAIL_ADDRESS>

@xevolesi Hello, I'm in need of the ThermalGAN.pth weights for a research project and was wondering if you might be able to share them with me. If you have the file and are willing to share, could you please send it to<EMAIL_ADDRESS>

Hello guys!  People often email me asking for pretrained weights. I can't share downloaded weights with you, because i downloaded it almost 6 years ago. I downloaded this weights to computing server at my previous job and now i DON'T have an access to this server and i DONT have any copy of this weights on my personal computer or file storage. I don't mind sharing pretrained weights with you, but I don't have them. Pretrained weights were left on the computing server at my previous job.

http://zefirus.org/datasets/models/ThermalGAN/ThermalGAN.pth

hi Sir，could you share the link again？This link unwork,thank you

Hi, ALL
i find the pretrain model,
3 years ago, i have download in my PC,
and i found it,
https://drive.google.com/file/d/19tqBi3Rph-W3F6qqGQ2irZzht8NPqi-3/view?usp=sharing
(this zip have some my file, please skip or del it )

http://zefirus.org/datasets/models/ThermalGAN/ThermalGAN.pth

hi Sir，could you share the link again？This link unwork,thank you

https://drive.google.com/file/d/19tqBi3Rph-W3F6qqGQ2irZzht8NPqi-3/view?usp=sharing
(this zip have some my file, please skip or del it )


Peering Request

Full Name
Multiway Comercio e Representações LTDA
ASN
AS274676
PeeringDB Integration

[X] My PeeringDB Entries are current
[ ] Peer at ALL EXCHANGES (and skip the Peer Address(es) field below)

Peer Address(es)
2001:12f8::220:53
Multihop

[ ] Multihop Peering Request

hi
Thnak you for your interest in peering with RouteViews.   We are unfortunately at capacity on our collector in Sao Paulo, so for now we have to decline this request.
Thanks for understanding
BR
Nina


Bot help

I got this problem with my bot.
http://pastebin.com/YyThCghE
Can anyone help me?

Same problem

Please check all files which requires the passwords.txt and make sure the path is correct.
This  problem gets nearly posted every single day.

@TheAnthonyNL
you already helped me with teamviewer. xD
Someone can close this

@GreYzZ  i know but it was meant for @Braandn  :D.


Update graph_db_custom_prompt.ts

To avoid missing parameter error as https://github.com/langchain-ai/langchain/issues/11706, we should use double curly brackets in the cypher examples

Thank you!


astropy error

Hello,
Running tiptop with the last version 1.2 seems to occur an error. It is astropy.io.fits.cards which returns an error as a FITS keyword is too long. I use astropy version 4.2. The keyword in question has been added by the commit #41.
The bug can be reproduced by running the example given in the Quickstart section of the tiptop documentation:
overallSimulation("perfTest", "HarmoniSCAO_1", "perfTest", "testPyramid", doPlot=False, doConvolve=False)
Kind regards,
Laure

There is an 80-character limit in the fits header (https://heasarc.gsfc.nasa.gov/docs/heasarc/fits_overview.html) so you cannot add parameter key values that are longer than this.
Unfortunately in the ini file you are using there are keys (in the [telescope] section) that have long strings as their values.
We will look for a way around this problem.

Solved with pull request https://github.com/astro-tiptop/TIPTOP/pull/60


compiling c++ code with TFLite library gives error with cstring

System information

Have I written custom code (as opposed to using a stock example script provided in TensorFlow): Yes
OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 16.04
TensorFlow installed from (source or binary): N/A (using only source files)
TensorFlow version (use command below): N/A
Python version: 2.7.12
Bazel version (if compiling from source): 0.13.0
GCC/Compiler version (if compiling from source): g++ 5.4.0
CUDA/cuDNN version: N/A
GPU model and memory: N/A
Exact command to reproduce:

Describe the problem
Describe the problem clearly here. Be sure to convey here why it's a bug in TensorFlow or a feature request.
I'm trying to compile custom c++ code with command
g++ -std=c++11 -Itensorflow/contrib/lite -I. -Lbazel-bin/tensorflow/contrib/lite -tflite test.cpp -o test
and it gives some error that some functions in cstring cannot be found.
When I delete line #include <cstring> from flatbuffers/base.h, errors from cstring disappear but others remain. Including cstring in flatbuffers.h also gives same errors.
I'm using flatbuffers cloned from git google flatbuffers repository. Is this can be a problem?
I've made c++ tensorflow lite library with command
bagel build //tensorflow/contrib/lite:framework
with lite/BUILD including
cc_binary(     name = "libtflite.so",     deps = [         ":framework",         "//tensorflow/contrib/lite/kernels:builtin_ops"],     ] )
Thanks.
Source code / logs
Include any logs or source code that would be helpful to diagnose the problem. If including tracebacks, please include the full traceback. Large logs and files should be attached. Try to provide a reproducible test case that is the bare minimum necessary to generate the problem.
C++ Code
  1 #include <stdio.h>
  2
  3 #include "tensorflow/contrib/lite/kernels/register.h"
  4 #include "tensorflow/contrib/lite/model.h"
  5 #include "tensorflow/contrib/lite/string_util.h"
  6 #include "tensorflow/contrib/lite/tools/mutable_op_resolver.h"
  7
  8
  9
 10 int main(){
 11     const char* graph_path = "xorGate.lite";
 12     const int num_threads = 1;
 13     std::string input_layer_type = "float";
 14     float x,y;
 15
 16     std::unique_ptr<tflite::FlatBufferModel> model(
 17         tflite::FlatBufferModel::BuildFromFile(graph_path));
 18
 19     if(!model){
 20         printf("Failed to mmap model\n");
 21         exit(0);
 22     }
 23
 24     tflite::ops::builtin::BuiltinOpResolver resolver;
 25     std::unique_ptr<tflite::Interpreter> interpreter;
 26     tflite::InterpreterBuilder(*model, resolver)(&interpreter);
 27
 28     if(!interpreter){
 29         printf("Failed to construct interpreter\n");
 30         exit(0);
 31     }
 32
 33     if(num_threads != 1){
 34         interpreter->SetNumThreads(num_threads);
 35     }
 36
 37     float* input = interpreter->typed_input_tensor<float>(0);
 38
 39     if(interpreter->AllocateTensors() != kTfLiteOk){
 40         printf("Failed to allocate tensors\n");
 41         exit(0);
 42     }
 43
 44     //read two numbers
 45     std::printf("Type two float numbers : ");
 46     std::scanf("%f %f", &x, &y);
 47     input[0] = x;
 48     input[1] = y;
 49
 50     if(interpreter->Invoke() != kTfLiteOk){
 51         std::printf("Failed to invoke!\n");
 52         exit(0);
 53     }
 54     float* output = interpreter->typed_output_tensor<float>(0);
 55     printf("output = %f\n", output[0]);
 56     return 0;
 57 }

Log
In file included from ./flatbuffers/base.h:2:0,
                 from ./flatbuffers/flatbuffers.h:18,
                 from ./tensorflow/contrib/lite/schema/schema_generated.h:21,
                 from ./tensorflow/contrib/lite/model.h:40,
                 from tensorflow/contrib/lite/kernels/register.h:20,
                 from test.cpp:1:
/usr/include/c++/5/cstring:75:11: error: ‘::memchr’ has not been declared
   using ::memchr;
/usr/include/c++/5/cstring:76:11: error: ‘::memcmp’ has not been declared
   using ::memcmp;
/usr/include/c++/5/cstring:77:11: error: ‘::memcpy’ has not been declared
   using ::memcpy;
/usr/include/c++/5/cstring:78:11: error: ‘::memmove’ has not been declared
   using ::memmove;
/usr/include/c++/5/cstring:79:11: error: ‘::memset’ has not been declared
   using ::memset;
/usr/include/c++/5/cstring:80:11: error: ‘::strcat’ has not been declared
   using ::strcat;

...
same error from different functions
...

In file included from ./tensorflow/contrib/lite/schema/schema_generated.h:21:0,
                 from ./tensorflow/contrib/lite/model.h:40,
                 from tensorflow/contrib/lite/kernels/register.h:20,
                 from test.cpp:1:
./flatbuffers/flatbuffers.h: In member function ‘bool flatbuffers::String::operator<(const flatbuffers::String&) const’:
./flatbuffers/flatbuffers.h:346:12: error: ‘strcmp’ is not a member of ‘std’
     return std::strcmp(c_str(), o.c_str()) < 0;
            ^
./flatbuffers/flatbuffers.h: In member function ‘void flatbuffers::Allocator::memcpy_downward(uint8_t*, size_t, uint8_t*, size_t, size_t, size_t)’:
./flatbuffers/flatbuffers.h:387:23: error: ‘memcpy’ was not declared in this scope
            in_use_back);
                       ^
./flatbuffers/flatbuffers.h: In member function ‘void flatbuffers::vector_downward::push(const uint8_t*, size_t)’:
./flatbuffers/flatbuffers.h:628:39: error: ‘memcpy’ was not declared in this scope
     memcpy(make_space(num), bytes, num);
                                       ^
./flatbuffers/flatbuffers.h: In member function ‘void flatbuffers::vector_downward::fill_big(size_t)’:
./flatbuffers/flatbuffers.h:652:57: error: ‘memset’ was not declared in this scope
     memset(make_space(zero_pad_bytes), 0, zero_pad_bytes);
                                                         ^
./flatbuffers/flatbuffers.h: In member function ‘flatbuffers::uoffset_t flatbuffers::FlatBufferBuilder::EndTable(flatbuffers::uoffset_t)’:
./flatbuffers/flatbuffers.h:982:62: error: ‘memcmp’ was not declared in this scope
         if (vt1_size != vt2_size || memcmp(vt2, vt1, vt1_size)) continue;
                                                              ^
./flatbuffers/flatbuffers.h: In member function ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateString(const char*)’:
./flatbuffers/flatbuffers.h:1061:40: error: ‘strlen’ was not declared in this scope
     return CreateString(str, strlen(str));
                                        ^
./flatbuffers/flatbuffers.h: In member function ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateString(char*)’:
./flatbuffers/flatbuffers.h:1068:40: error: ‘strlen’ was not declared in this scope
     return CreateString(str, strlen(str));
                                        ^
./flatbuffers/flatbuffers.h: In member function ‘flatbuffers::Offset<flatbuffers::String> flatbuffers::FlatBufferBuilder::CreateSharedString(const char*)’:
./flatbuffers/flatbuffers.h:1124:46: error: ‘strlen’ was not declared in this scope
     return CreateSharedString(str, strlen(str));
                                              ^
In file included from ./flatbuffers/base.h:12:0,
                 from ./flatbuffers/flatbuffers.h:18,
                 from ./tensorflow/contrib/lite/schema/schema_generated.h:21,
                 from ./tensorflow/contrib/lite/model.h:40,
                 from tensorflow/contrib/lite/kernels/register.h:20,
                 from test.cpp:1:
./flatbuffers/flatbuffers.h: In member function ‘void flatbuffers::FlatBufferBuilder::Finish(flatbuffers::uoffset_t, const char*, bool)’:
./flatbuffers/flatbuffers.h:1563:48: error: ‘strlen’ was not declared in this scope
       FLATBUFFERS_ASSERT(strlen(file_identifier) == kFileIdentifierLength);
                                                ^
./flatbuffers/flatbuffers.h:1563:7: note: in expansion of macro ‘FLATBUFFERS_ASSERT’
       FLATBUFFERS_ASSERT(strlen(file_identifier) == kFileIdentifierLength);
       ^
In file included from ./tensorflow/contrib/lite/schema/schema_generated.h:21:0,
                 from ./tensorflow/contrib/lite/model.h:40,
                 from tensorflow/contrib/lite/kernels/register.h:20,
                 from test.cpp:1:
./flatbuffers/flatbuffers.h: In member function ‘bool flatbuffers::FlatBufferBuilder::StringOffsetCompare::operator()(const flatbuffers::Offset<flatbuffers::String>&, const flatbuffers::Offset<flatbuffers::String>&) const’:
./flatbuffers/flatbuffers.h:1604:64: error: ‘strncmp’ was not declared in this scope
                      (std::min)(stra->size(), strb->size()) + 1) < 0;
                                                                ^
./flatbuffers/flatbuffers.h: In function ‘bool flatbuffers::BufferHasIdentifier(const void*, const char*, bool)’:
./flatbuffers/flatbuffers.h:1676:58: error: ‘strncmp’ was not declared in this scope
                  FlatBufferBuilder::kFileIdentifierLength) == 0;
                                                          ^
./flatbuffers/flatbuffers.h: In function ‘int flatbuffers::LookupEnum(const char**, const char*)’:
./flatbuffers/flatbuffers.h:2119:10: error: ‘strcmp’ is not a member of ‘std’
     if (!std::strcmp(*p, name)) return static_cast<int>(p - names);

Nagging Assignee @andrehentz: It has been 14 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

Nagging Assignee @andrehentz: It has been 15 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

Nagging Assignee @andrehentz: It has been 30 days with no activity and this issue has an assignee. Please update the label and/or status accordingly.

@timedilation  Have you  solved this problem?

I am also getting this same error.
Any idea in how to solve this error?

Same error too, need help.......

Don't know how to solve this issue, but there is another "string.h" file in folder "tensorflow/lite" and it seems that the compiler use this file instead.

Don't know how to solve this issue, but there is another "string.h" file in folder "tensorflow/lite" and it seems that the compiler use this file instead.

Not sure if this is the proper way, but removing the string.h under tensorflow/lite will at least pass the build

Not sure if applicable but please see if my resolution is helpful for your case. For me, the issue disappeared once I removed the tensorflow/lite from include paths.
Earlier compile command (with the same errors as author):
g++ -std=c++11 -Itensorflow-1.13.1 -Itensorflow-1.13.1/tensorflow/lite -Itensorflow-1.13.1/tensorflow/lite/tools/make/downloads/flatbuffers/include main.cpp -o main.out -ltensorflow-lite
Adjusted compile command (with issue resolved):
g++ -std=c++11 -Itensorflow-1.13.1 -Itensorflow-1.13.1/tensorflow/lite/tools/make/downloads/flatbuffers/include main.cpp -o main.out -ltensorflow-lite

Not sure if applicable but please see if my resolution is helpful for your case. For me, the issue disappeared once I removed the tensorflow/lite from include paths.
Earlier compile command (with the same errors as author):
g++ -std=c++11 -Itensorflow-1.13.1 -Itensorflow-1.13.1/tensorflow/lite -Itensorflow-1.13.1/tensorflow/lite/tools/make/downloads/flatbuffers/include main.cpp -o main.out -ltensorflow-lite
Adjusted compile command (with issue resolved):
g++ -std=c++11 -Itensorflow-1.13.1 -Itensorflow-1.13.1/tensorflow/lite/tools/make/downloads/flatbuffers/include main.cpp -o main.out -ltensorflow-lite

This solution worked for me. The issue may be caused by the string.h implemented by TF. The string.h in tensorflow/lite doesn't define "memcpy memset......". Thus, remove tensorflow/lite from include_directories.
Thanks a lot.


HVAC mode on Main heat_cool not turning on

Using this on my 2022 397TH-R the heat_cool option does not take effect when trying to select it.  Heat and Cool separately work

I no longer have access to a OneControl environment for testing and development, but willing to help remotely if interested.


Makefile pipinstall

makefile pip install with default python version and separated from pip3install to solve cmd invalid error

This fixes installation of autopy from source


PR: Ensure plugin actions are enabled before adding them to the menu

Description of Changes

[ ] Wrote at least one-line docstrings (for any new functions)
[ ] Added unit test(s) covering the changes (if testable)

[x] Included a screenshot or animation (if affecting the UI, see Licecap)

Enable all the actions when refreshing them for example when undocking:

Issue(s) Resolved

Fixes #11591
Affirmation
By submitting this Pull Request or typing my (user)name below,
I affirm the Developer Certificate of Origin
with respect to all commits and content included in this PR,
and understand I am releasing the same under Spyder's MIT (Expat) license.

I certify the above statement is true and correct:

Hello @dalthviz! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

In the file spyder/plugins/base.py:

Line 412:3: E111 indentation is not a multiple of four

Note: I'm quite unsure about the PEP8 error that popped-up (seems like the line has an indentation of 12 spaces / 3 tabs).


Deactivating high contrast mode does not respect originally selected theme

Hey, hey! Just installed this using the moderndeck-bin AUR package, but I was also able to reproduce this on the Flatpak. I'm running Arch Linux (btw). This feels like a styling thing, so it probably affects more platforms than mine...
After setting a theme...

...and switching to High Contrast mode...

...when you switch BACK, ModernDeck doesn't respect the theme you originally selected and goes back to the default (but with the right highlight color).

Let me know if you need more info.
Loving the app, by the way!

Yeah this behavior is kind of for technical reasons as high contrast uses AMOLED as a base. I should probably figure out a way to handle this better for users?


x/pkgsite: dd-trace-go incorrect latest version

What is the URL of the page with the issue?
https://pkg.go.dev/gopkg.in/datadog/dd-trace-go.v1
What did you expect to see?
Latest version should be v1.48.0 (the current latest version that is returned when asking proxy.golang.org for latest:
{"Version":"v1.48.0","Time":"2023-02-27T08:40:48Z","Origin":{"VCS":"git","URL":"https://gopkg.in/DataDog/dd-trace-go.v1","Ref":"refs/tags/v1.48.0","Hash":"34ff76387d2f267007cee508

What did you see instead?
Current latest version seems to be stuck at v1.24.1. This looks like when the project converted from having no go.mod to a valid go.mod (unsure if that is coincidence or not). Essentially the project version got stuck after that.

The name is case sensitive, it should be "DataDog" (this doesn't match Datadog's branding, but oh well):
https://pkg.go.dev/gopkg.in/DataDog/dd-trace-go.v1
That link is up to date.


Don't import modules, keep as paths

Was having issues rebuilding a cluster
error: A definition for option `cluster.autoscalingGroups.client-us-east-2-c5-4xlarge.modules.[definition 1-entry 1]' is not of type `path or attribute set'. Definition values:
       - In `/nix/store/sz6yw0k00rhm689n62agi865gxydh3kj-source/clusters/<cluster>/testnet/default.nix': <function, args: {config, lib, pkgs, self}>

       … while evaluating the attribute 'value'
       ```

see f2be009 and 72ab68f

actually, this wasn't fixed, the mkHashiStack is still affected

going to merge this to unblock myself. I can't find anywhere were path attr is still being enforced. The trace just seems to be from the evalModules from nixos, but the stack could also not be reflective of the types being declared earlier

Well if there is still an underlying issue I'm sure it will rear its head at some point. For now this should be fine :+1:


Panel doesn't show elements having v-if

A panel doesn't increase it's height when an inner element's v-if condition that was initially false turns true. Is this behavior intended or is this an issue?
https://jsfiddle.net/mhb3epfe/6/
html:

  <panel header="this panel works" :is-open="true">
    <input type="checkbox" v-model="initiallyChecked" /> show the conditional list

      conditional list:

a

b

c

  </panel>
  <panel header="this panel doesn't work" :is-open="true">
    <input type="checkbox" v-model="initiallyUnchecked" /> show the conditional list

      conditional list:

a

b

c

  </panel>

js:
new Vue({
  el: '#app',
  data() {
    return {
      initiallyChecked: true,
      initiallyUnchecked: false
    }
  },
  components: {
    panel: VueStrap.panel
  }
})

I think it's because the max-height property of the panels content is evaluated when the panel component is ready. When I remove that code line, the contend expands nicely for the initially disabled element, but the transition doesn't apply. Is there some method that doesn't break the transition?
This applies to v-show too.

I think add a resize listener to panel and re-evaluate the height may work. I will try to fix when I get a decent network condition. (I can’t access some website like Google or GitHub in my country)
 You can hack like this for a temporary solution: https://jsfiddle.net/mhb3epfe/8/
在 2016年1月11日 下午7:39:58, Marco<EMAIL_ADDRESS>写到:
A panel doesn't increase it's height when an inner element's v-if condition that was initially false turns true Is this behavior intended or is this an issue?
https://jsfiddlenet/mhb3epfe/6/
html:

 show the conditional list

      conditional list:abc

 show the conditional list

      conditional list:abc

js:
new Vue({
el: '#app',
data() {
return {
initiallyChecked: true,
initiallyUnchecked: false
}
},
components: {
panel: VueStrappanel
}
})
I think it's because the max-height property of the panels content is evaluated when the panel component is ready When I remove that code line, the contend expands nicely for the initially disabled element, but the transition doesn't apply Is there some method that doesn't break the transition?
This applies to v-show too
—
Reply to this email directly or view it on GitHub.

I created patch #126 which calculates the max-height only when the panel is about to collapse instead of during the ready event. It may fix your problem.


Add level/layer support

Description
Currently when somebody is mapping malls with multiple floors or underground features (like shops in pedestrian underpasses or metro stations) users have to see all other elements that are not on that level (like roads, crossings etc.) The same is true when you edit ground features. It's easy to connect something to something else from a different level by mistake.
My proposal is to create some sort of UI which shows you on which level/layer/floor you are on and show things that are only on it. You should be able to add new features to it and iD should automatically add level/layer tag.
Screenshots

A good initial design could be the one used in iD-indoor.

I would like this to get implemented, there was a guy that tried it but gave up #3097


bg-color_search-icon-color_cancel-icon-color

hey @prudhvikatlaparthi thanks for the pr
could you update it taking into consideration the current status of the project?