Add first draft of Bernstein polynomial flow

Hello,
I am the co-author of the Bernstein-Flows paper https://arxiv.org/abs/2004.00464 in which we constructed a one-dimensional flow based on Bernstein polynomials. We already have a TF implementation.
This flow would fit nicely in the zuko framework as an alternative to NSF. I am not an expert in software development and pytorch. I managed to write a transformation and also a flow. The "test_transform" works and I have usd the flow successfully for training, but I still have an exception in the unit test (test_flows) at the following position
for p in flow.parameters():
    assert p.grad is not None

I tried hard but could not find any reason why this was failing. Possibly I lack the knowledge of the bells and whistles of your package. Could you please consider the request?
Best,
Oliver and Marcel (@marpogaus)

Hello @oduerr, thank your for your PR and contributing! I took a (very) quick look and could not find where the bug come from, especially if you were able to train successfully. This part of the test is to ensure that all parameters are used and registered within the computation graph.
FYI, I'll be flying to NeurIPS tomorrow, so I might not be able to look for the bug before the end of the conference. Thanks again!

Hello @oduerr, thank your for your PR and contributing! I took a (very) quick look and could not find where the bug come from, especially if you were able to train successfully. This part of the test is to ensure that all parameters are used and registered within the computation graph. I'll have to dig deeper, but I'll be flying to NeurIPS tomorrow, so I might not be able to before the end of the conference. Thanks again and sorry for the wait.

Hello @francois-rozet,
thank you very much for your fast reply (and sorry for my late answer). Concerning training, I made a small notebook https://github.com/oduerr/zuko/blob/bernstein/oliver_tester/bern_tester.ipynb demonstrating the successful training for an unconditional 1-D distribution.
A side remark concerning the training: if I understand the framework correctly, it is built so that during training, the inverse is used (Flow goes from "Latent to Data").  Is it possible to specify the flow in a way that in the training no inverse is used (Flow goes from "Data to Latent")? It would be great if one could choose the direction and trade-off training vs. sampling.
No pressure with your reply; enjoy NeurIPS first!
Best,
Oliver

Hi @francois-rozet,
Thank you for your prompt response.
Is there anything we can do to assist in resolving the issues and merge this PR?
Best regards,
Marcel

I was just wondering: Could this class be used to train using the forward transformation, as @oduerr suggests?
The relevant part in my tfp Implementation can be found here.

Hello @oduerr and @MArpogaus, I will take a look at this now.

A side remark concerning the training: if I understand the framework correctly, it is built so that during training, the inverse is used (Flow goes from "Latent to Data").

So it is actually the opposite. In Zuko, the forward is assumed to be "data to latent". This is because the inverse of some transformations is not differentiable.

It would be great if one could choose the direction and trade-off training vs. sampling.

It is already the case actually, and it is indeed related to LazyInverse @MArpogaus! Basically, if you have a LazyTransform, you can reverse it with .inv.
For example, in the training from energy tutorial, I use .inv to reverse the transformation of an auto-regressive NSF.

@oduerr I have an issue. I cannot pull your PR on my computer because of the branch name which contains a emoji :laughing: Would it be possible to rename your branch (without the emoji) and re-submit a PR if necessary?

Hello again @oduerr and @MArpogaus, since I was unable to pull this PR. I copied the code and created a branch (#33) on the Zuko repo. In addition to fixing the bug with phi, I have made some changes:

As a polynomial flow, I moved the flow to the zuko.flows.polynomial module. I also renamed it BPF (Bernstein polynomial flow) to follow Zuko's conventions.
I used torch.arange(1, degree + 1) instead of torch.tensor(range(1, degree)) to create $\alpha$ and $\beta$.
I used the sigmoid function $\sigma(x) = \frac{1}{1 + \exp(-x)}$ to map the inputs to $[0, 1]$ instead of $\frac{x + B}{2B}$. This ensures that the domain is $\mathbb{R}$. Note that the transform is only invertible for the domain $[-B, B]$ because these are the initial bounds of the bisection method.

Otherwise, its the same. Great job! Tell me if there is you see a mistake in #33.

Hello Francois,
thank you very much for taking care of this! I guess I was overdoing it
with the emojis, sorry ;-)
I went over the code and had a look at your changes. They all look fine.
Concerning point 3, the sigmoid is a good idea. For the very same reason,
we had this in our original paper. But we sometimes found it beneficial to
linearly map $[-B,B]$ to $[0,1]$ (especially when the bounds are known).
Would it be possible to have the sigmoid as a save default setting but also
have the option to linearly map $[-B,B]$ to $[0,1]$?
Along these lines, would it be possible to linearly extrapolate bounded
transformations, using the values and derivatives at the bounds? This would
be also an option for other bounded transformations.
I am impressed with the speed of zuko, we had no implementations as fast as
zuko of our flows. Thanks!
On Fri, 12 Jan 2024 at 23:44, François Rozet @.***>
wrote:

Hello again @oduerr https://github.com/oduerr and @MArpogaus
https://github.com/MArpogaus, since I was unable to pull this PR. I
copied the code and created a branch (#33
https://github.com/probabilists/zuko/pull/33) on the Zuko repo. In
addition to fixing the bug with phi, I have made some changes:

As a polynomial flow, I moved the flow to the zuko.flows.polynomial
module. I also renamed it BPF (Bernstein polynomial flow) to follow
Zuko's conventions.
I used torch.arange(1, degree + 1) instead of torch.tensor(range(1,
degree)) to create $\alpha$ and $\beta$.
I used the sigmoid function $\sigma(x) = \frac{1}{1 + \exp(-x)}$ to
map the inputs to $[0, 1]$ instead of $\frac{x + B}{2B}$. This ensures
that the domain is $\mathbb{R}$. Note that the transform is only
invertible for the domain $[-B, B]$ because these are the initial
bounds of the bisection method.

Otherwise, its the same. Great job! Tell me if there is you see a mistake
in #33 https://github.com/probabilists/zuko/pull/33.
—
Reply to this email directly, view it on GitHub
https://github.com/probabilists/zuko/pull/32#issuecomment-1890078545,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/ABDEA5B664DYM534A4DT46TYOG4FFAVCNFSM6AAAAABALDFAKOVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQOJQGA3TQNJUGU
.
You are receiving this because you were mentioned.Message ID:
@.***>

But we sometimes found it beneficial to linearly map $[-B,B]$ to $[0,1]$ (especially when the bounds are known). Would it be possible to have the sigmoid as a save default setting but also have the option to linearly map $[-B,B]$ to $[0,1]$?

Yes it is possible to add the option to switch to a linear map. However, because the output of the transformation is unbounded, stacking several Bernstein transformations would likely fail during training.
I like your proposition of linearly extrapolating outside of the bounds better. This is what spline transformations do actually. However, for splines it is trivial to compute the values and derivatives at the bounds. For your case, I don't see how to do it cheaply/easily.
I propose to add the option to switch to a linear map instead of a sigmoid (+ assert that inputs are in bounds) in #33 and merge the PR. Then you can submit a PR that adds the linear extrapolation feature (for SOSPF also maybe?) later on. WDYT?

I am impressed with the speed of zuko, we had no implementations as fast as zuko of our flows. Thanks!

Thanks!

I like your proposition of linearly extrapolating outside of the bounds better. This is what spline transformations do actually. However, for splines it is trivial to compute the values and derivatives at the bounds. For your case, I don't see how to do it cheaply/easily.

Extrapolating the Bernstein Polynomial is trivial, when exploiting its properties.
I did it (here)[https://github.com/MArpogaus/TensorFlow-Probability-Bernstein-Polynomial-Bijector/blob/70a7fa3f641f11303cf000ed4b24813c21a610a6/src/bernstein_flow/bijectors/bernstein_extra.py#L13] before for the tf Implementation and hopefully find some time next week to look into this and create a new PR.
@oduerr: Maybe we can have a call by the beginning of next week to discuss the matter?

I propose to add the option to switch to a linear map instead of a sigmoid (+ assert that inputs are in bounds) in #33 and merge the PR. Then you can submit a new PR (or an issue if you don't know how to tackle this either)
that adds the linear extrapolation feature later on. WDYT?

Sounds good to me. Thanks :)
One more general question: Is there code available where you evaluate typical flows on established benchmark data like the one provided from @gpapamak here?
If not, here is a self contained script to download, verify and prepare the data provided above. I will use this as a starting point to do some comparisons.
"""Access functions for benchmark datasets."""
import hashlib
import os
import tarfile
import urllib.request
from collections import Counter

import h5py
import numpy as np
import pandas as pd

# Define the URLs for downloading the preprocessed data archive and its MD5 checksum
DATA_ARCHIVE_URL = "https://zenodo.org/record/1161203/files/data.tar.gz"
MD5_CHECKSUM = "9b9c9b0375315ad270eba4ce80c093ab"

def download_and_verify_data(download_path):
    """Download the preprocessed data archive and verifies its MD5 checksum.

    :return: Path to the downloaded data archive.
    :rtype: str
    """
    # Create the dataset directory if it doesn't exist
    os.makedirs(download_path, exist_ok=True)

    # Calculate MD5 checksum of the downloaded file
    md5 = hashlib.md5()
    data_archive_file = os.path.join(download_path, "data.tar.gz")

    # Download the data archive if it doesn't exist
    if not os.path.exists(data_archive_file):
        print("Downloading data archive...")
        urllib.request.urlretrieve(DATA_ARCHIVE_URL, data_archive_file)

    # Verify MD5 checksum
    with open(data_archive_file, "rb") as f:
        while chunk := f.read(8192):
            md5.update(chunk)

    if md5.hexdigest() != MD5_CHECKSUM:
        raise ValueError("MD5 checksum does not match.")

    return data_archive_file

def extract_dataset(dataset_name, dataset_path):
    """Extract dataset."""
    data_archive_file = download_and_verify_data(dataset_path)
    dataset_dir = os.path.join(dataset_path, dataset_name.lower())

    # Extract the dataset if it hasn't been extracted yet
    if not os.path.exists(dataset_dir) or (
        os.path.exists(dataset_dir)
        and not list(
            filter(lambda fn: not fn.endswith(".dvc"), os.listdir(dataset_dir))
        )
    ):
        print(f"Extracting {dataset_name} dataset...")
        # Define the allowed file extensions
        allowed_extensions = (".csv", ".pickle", ".npy", ".hdf5")
        # Define the prefix for files to be extracted
        file_prefix = f"DATA/{dataset_name}"

        # Open the data archive
        with tarfile.open(data_archive_file, "r:gz") as tar:
            # Iterate through files in the archive
            for member in tar.getmembers():
                if (
                    member.isfile()
                    and member.name.upper().startswith(file_prefix)
                    and "/." not in member.name
                    and member.name.endswith(allowed_extensions)
                ):
                    # Extract the file to the dataset directory
                    member.name = os.path.basename(member.name)  # Remove leading path
                    print(f"Extracting {member.name} to {dataset_dir}...", end="")
                    tar.extract(member, path=dataset_dir)
                    print("done.")

    return dataset_dir

def load_and_preprocess_data(dataset_name, dataset_path):
    """Load and preprocesse the specified dataset.

    :param str dataset_name: Name of the dataset (e.g., "POWER", "GAS", etc.).
    :return: Tuple containing the training, validation, and test data arrays.
    :rtype: tuple
    """
    dataset_name = dataset_name.upper()

    # Load the data and apply preprocessing as per the original code
    if dataset_name == "POWER":
        dataset_dir = extract_dataset(dataset_name, dataset_path)
        return load_and_process_power_data(dataset_dir)
    elif dataset_name == "GAS":
        dataset_dir = extract_dataset(dataset_name, dataset_path)
        return load_and_process_gas_data(dataset_dir)
    elif dataset_name == "HEPMASS":
        dataset_dir = extract_dataset(dataset_name, dataset_path)
        return load_and_process_hepmass_data(dataset_dir)
    elif dataset_name == "MINIBOONE":
        dataset_dir = extract_dataset(dataset_name, dataset_path)
        return load_and_process_miniboone_data(dataset_dir)
    elif dataset_name == "BSDS300":
        dataset_dir = extract_dataset(dataset_name, dataset_path)
        return load_and_process_bsds300_data(dataset_dir)
    else:
        raise ValueError(f"Dataset '{dataset_name}' is not supported.")

def load_and_process_power_data(dataset_dir):
    """Load data."""
    # https://github.com/gpapamak/maf/blob/master/datasets/power.py

    def load_data_split_with_noise(data):
        rng = np.random.RandomState(42)

        rng.shuffle(data)
        N = data.shape[0]

        data = np.delete(data, 3, axis=1)
        data = np.delete(data, 1, axis=1)
        ############################
        # Add noise
        ############################
        # global_intensity_noise = 0.1*rng.rand(N, 1)
        voltage_noise = 0.01 * rng.rand(N, 1)
        # grp_noise = 0.001*rng.rand(N, 1)
        gap_noise = 0.001 * rng.rand(N, 1)
        sm_noise = rng.rand(N, 3)
        time_noise = np.zeros((N, 1))
        noise = np.hstack((gap_noise, voltage_noise, sm_noise, time_noise))
        data = data + noise

        N_test = int(0.1 * data.shape[0])
        data_test = data[-N_test:]
        data = data[0:-N_test]
        N_validate = int(0.1 * data.shape[0])
        data_validate = data[-N_validate:]
        data_train = data[0:-N_validate]

        return data_train, data_validate, data_test

    def load_data_normalised(data):
        data_train, data_validate, data_test = load_data_split_with_noise(data)
        data = np.vstack((data_train, data_validate))
        mu = data.mean(axis=0)
        s = data.std(axis=0)
        data_train = (data_train - mu) / s
        data_validate = (data_validate - mu) / s
        data_test = (data_test - mu) / s

        return data_train, data_validate, data_test

    data = np.load(dataset_dir + "/data.npy")
    data_train, data_validate, data_test = load_data_normalised(data)
    return (data_train, data_validate, data_test), data_train.shape[-1]

def load_and_process_gas_data(dataset_dir):
    """Load data."""

    # https://github.com/gpapamak/maf/blob/master/datasets/gas.py
    def load_data(file):
        data = pd.read_pickle(file)
        # data = pd.read_pickle(file).sample(frac=0.25)
        # data.to_pickle(file)
        data.drop("Meth", axis=1, inplace=True)
        data.drop("Eth", axis=1, inplace=True)
        data.drop("Time", axis=1, inplace=True)
        return data

    def get_correlation_numbers(data):
        C = data.corr()
        A = C > 0.98
        B = A.as_matrix().sum(axis=1)
        return B

    def load_data_and_clean(file):
        data = load_data(file)
        B = get_correlation_numbers(data)

        while np.any(B > 1):
            col_to_remove = np.where(B > 1)[0][0]
            col_name = data.columns[col_to_remove]
            data.drop(col_name, axis=1, inplace=True)
            B = get_correlation_numbers(data)
        # print(data.corr())
        data = (data - data.mean()) / data.std()

        return data

    def load_data_and_clean_and_split(file):
        data = load_data_and_clean(file).as_matrix()
        N_test = int(0.1 * data.shape[0])
        data_test = data[-N_test:]
        data_train = data[0:-N_test]
        N_validate = int(0.1 * data_train.shape[0])
        data_validate = data_train[-N_validate:]
        data_train = data_train[0:-N_validate]

        return data_train, data_validate, data_test

    file = dataset_dir + "/ethylene_CO.pickle"
    data_train, data_validate, data_test = load_data_and_clean_and_split(file)
    return (data_train, data_validate, data_test), data_train.shape[-1]

def load_and_process_hepmass_data(dataset_dir):
    """Load data."""

    # https://github.com/gpapamak/maf/blob/master/datasets/hepmass.py
    # https://github.com/bayesiains/nsf/blob/master/data/hepmass.py
    def load_data(path):
        data_train = pd.read_csv(
            filepath_or_buffer=os.path.join(path, "1000_train.csv"), index_col=False
        )
        data_test = pd.read_csv(
            filepath_or_buffer=os.path.join(path, "1000_test.csv"), index_col=False
        )

        return data_train, data_test

    def load_data_no_discrete(path):
        """Load the positive class examples from the first 10% of the dataset."""
        data_train, data_test = load_data(path)

        # Gets rid of any background noise examples i.e. class label 0.
        data_train = data_train[data_train[data_train.columns[0]] == 1]
        data_train = data_train.drop(data_train.columns[0], axis=1)
        data_test = data_test[data_test[data_test.columns[0]] == 1]
        data_test = data_test.drop(data_test.columns[0], axis=1)
        # Because the data_ set is messed up!
        data_test = data_test.drop(data_test.columns[-1], axis=1)

        return data_train, data_test

    def load_data_no_discrete_normalised(path):
        data_train, data_test = load_data_no_discrete(path)
        mu = data_train.mean()
        s = data_train.std()
        data_train = (data_train - mu) / s
        data_test = (data_test - mu) / s

        return data_train, data_test

    def load_data_no_discrete_normalised_as_array(path):
        data_train, data_test = load_data_no_discrete_normalised(path)
        data_train, data_test = data_train.values, data_test.values

        i = 0
        # Remove any features that have too many re-occurring real values.
        features_to_remove = []
        for feature in data_train.T:
            c = Counter(feature)
            max_count = np.array([v for k, v in sorted(c.items())])[0]
            if max_count > 5:
                features_to_remove.append(i)
            i += 1
        data_train = data_train[
            :,
            np.array(
                [i for i in range(data_train.shape[1]) if i not in features_to_remove]
            ),
        ]
        data_test = data_test[
            :,
            np.array(
                [i for i in range(data_test.shape[1]) if i not in features_to_remove]
            ),
        ]

        N = data_train.shape[0]
        N_validate = int(N * 0.1)
        data_validate = data_train[-N_validate:]
        data_train = data_train[0:-N_validate]

        return data_train, data_validate, data_test

    path = dataset_dir
    data_train, data_validate, data_test = load_data_no_discrete_normalised_as_array(
        path
    )
    return (data_train, data_validate, data_test), data_train.shape[-1]

def load_and_process_miniboone_data(dataset_dir):
    """Load data."""

    def load_data(root_path):
        data = np.load(root_path)
        N_test = int(0.1 * data.shape[0])
        data_test = data[-N_test:]
        data = data[0:-N_test]
        N_validate = int(0.1 * data.shape[0])
        data_validate = data[-N_validate:]
        data_train = data[0:-N_validate]

        return data_train, data_validate, data_test

    def load_data_normalised(root_path):
        data_train, data_validate, data_test = load_data(root_path)
        data = np.vstack((data_train, data_validate))
        mu = data.mean(axis=0)
        s = data.std(axis=0)
        data_train = (data_train - mu) / s
        data_validate = (data_validate - mu) / s
        data_test = (data_test - mu) / s

        return data_train, data_validate, data_test

    file = dataset_dir + "/data.npy"
    data_train, data_validate, data_test = load_data_normalised(file)
    return (data_train, data_validate, data_test), data_train.shape[-1]

def load_and_process_bsds300_data(dataset_dir):
    """Load data."""
    # load dataset
    f = h5py.File(dataset_dir + "/BSDS300.hdf5", "r")

    data_train, data_validate, data_test = (
        f["train"][...],
        f["validation"][...],
        f["test"][...],
    )
    return (data_train, data_validate, data_test), data_train.shape[-1]

def get_dataset(dataset_name, dataset_path="datasets"):
    """Provide access to the specified dataset.

    :param str dataset_name: Name of the dataset (e.g., "POWER", "GAS", etc.).
    :return: Tuple containing the training, validation, and test data arrays.
    :rtype: tuple
    """
    return load_and_preprocess_data(dataset_name, dataset_path)

if __name__ == "__main__":
    import yaml

    shift_and_scale = {}
    for dataset_name in ("POWER", "HEPMASS", "MINIBOONE", "BSDS300"):
        print(f"=== {dataset_name} ===")
        (train_data, validation_data, _), dims = get_dataset(dataset_name)
        print(f"{dims=}")
        for d, split in zip((train_data, validation_data), ("train", "validate")):
            print(f"--- {split} ---")
            print(f"{type(d)=}")
            print(f"{d.shape=}")
            print(f"{d.min()=}")
            print(f"{d.max()=}")
            print(f"{d.std()=}")
            print(f"{d.mean()=}")

        d = train_data
        eps = 0.01
        data_min = np.min([train_data.min(0), validation_data.min(0)], 0)
        data_max = np.max([train_data.max(0), validation_data.max(0)], 0)
        shift = (-data_min + eps).round(3)
        scale = ((1 - 2 * eps) / (data_max - data_min)).round(3)

        print(f"{shift=}")
        print(f"{scale=}")

        scaled_train_data = (train_data + shift) * scale
        scaled_val_data = (validation_data + shift) * scale

        print(scaled_train_data.min(), scaled_train_data.max())
        print(scaled_val_data.min(), scaled_val_data.max())

        assert scaled_train_data.min() >= 0
        assert scaled_train_data.max() <= 1
        assert scaled_val_data.min() >= 0
        assert scaled_val_data.max() <= 1

        shift_and_scale[dataset_name.lower()] = dict(
            scale=scale.tolist(), shift=shift.tolist()
        )

    print(yaml.safe_dump({"benchmark_datasets": shift_and_scale}))

Sounds good to me. Thanks :)

Can I merge the PR #33 then?

Is there code available where you evaluate typical flows on established benchmark data like the one provided from @gpapamak here?

You can check https://github.com/francois-rozet/uci-datasets to download the data and the benchmark branch for benchmarks on toy problems.

P.S. Could you host your script somewhere else (e.g. a GitHub gist)? It makes it hard to navigate the discussion :sweat_smile:

Hello @oduerr and @MArpogaus, I have merged #33 :partying_face: and added you as authors. I will soon release a new version (1.1.0) of Zuko including BPF and other new features. Notably, it is now possible to instantiate unconditional univariate flows (features=1, context=0), which you noticed was impossible in your notebook.
I think we can now close the present PR and you are welcome to open a new issue/PR for the additional features we discussed.


[BUG] Avoid serializing Callable kwargs during Completion

Fixes #1759

Wow super cool, thanks @bahtman ! I'll review this more carefully but I think we can merge soon

Hmm, will the lru_cache work for callables? Do we need to add "ignore" parameter for the lru_cache to ignore callable_kwargs?

I was able to run the LM with a callable token provider. I’m unfamiliar with how the lru cache works, so unsure whether it actually caches the parameter.
This is a workaround so we don’t serialize it. But since we don’t serialize in the new Embed, it might be a relic? If that is the case we should just revert and remove the ujson part.

I did some digging. lru cache works as long as parameters are hashable (has hash() method)
https://docs.python.org/3/library/functools.html#functools.lru_cache
This is the case for callables, but not mutable containers like lists and dicts. This is probably the reason for the serialization.


An error occurred (UnrecognizedClientException) when calling the PutIntegration operation: The security token included in the request is invalid

I get this error randomly part-way through the "Creating API Gateway routes (this only happens once)" stage.
I'd tried a few things and it seems to fail somewhere between 8% and 11% through, which suggests to me that it's not doing the same operation. In fact, on one run it failed on "PutMethodResponse" and not "PutIntegration"
The only thing I can conclude is there is some kind of rate-limiting I'm hitting that Zappa is seeing as key issue, but key pair worked fine for the first 8-11% of the operation.
I can't see a way to "resume" the API Gateway part as it's part of the first-time "zappa deploy" command. That would give me a workaround here at least.

I found a workaround by limiting the parameter_depth and http_methods config values to precisely what I need (thus limiting the number of put actions on the API Gateway api). The progress bar moved much more quickly and finished before any error could occur.

Of course, there's still a bug or weird behaviour here if I had wanted to use deeper URLs and more methods.

I haven't encountered this, and it looks like a bit of a bastard to reproduce, but leaving this ticket open for now.
API Gateway path creation needs a real overhaul any, I'd much rather do it using something like troposphere and CloudFormation if possible, doing it one API call at a time is awful. API Gateway didn't used to be available in CF, I don't know if that's still the case.

I assume the code has changed enough now that I could have a check again to see if this still happens?

I can look into this if you have a way to reproduce, otherwise I can't really do anything about it. We are using CF, so this may not even be relevant. Checks would help though..


Gnuit

Please merge the high performance upgrade.  Much good. Very fast. Much speed.
Signed-off-by: QA-Lead-Team<EMAIL_ADDRESS>

Also, if you enjoy my contribution, please do not buy me a parrot figuring that it will be a fun surprise for me.  To acquire a parrot is a major decision: it is likely to outlive you.

Please merge. mUch good.


WKWebView Tester Feedback

Help us test Ionic with new WKWebView support in Cordova! Instructions on how to try it out are here: https://gist.github.com/mlynch/c63205f114def01ed0b9.
Please leave any feedback in the comments below.

work very smoothly on iPhone4S iOS 9.2 (13C75).
I will try to log energy and cpu usage to compare with WebView.

Neat stuff @mlynch, @shazron. The recipe at the gist does work.
My initial comments are as follows:

Probably the most used and needed CLI feature in our case is the live reload capability of "ionic run" on the command line and that does not seem to be working at this moment.

In the gist you specify  but according to the info at http://cordova.apache.org/announcements/2015/12/08/cordova-ios-4.0.0.html, it seems that cordova-plugin-whitelist is NOT needed for cordova-ios-4.0.0. So something to check.

Tried but got the following error:
The following build commands failed:
CompileC build/Open-climb.build/Debug-iphonesimulator/Open-climb.build/Objects-normal/i386/Diagnostic.o Open-climb/Plugins/cordova.plugins.diagnostic/Diagnostic.m normal i386 objective-c com.apple.compilers.llvm.clang.1_0.compiler
(1 failure)
Error: Error code 65 for command: xcodebuild with args: -xcconfig,~/oc/grades-cordova/platforms/ios/cordova/build-debug.xcconfig,-project,Open-climb.xcodeproj,ARCHS=i386,-target,Open-climb,-configuration,Debug,-sdk,iphonesimulator,build,VALID_ARCHS=i386,CONFIGURATION_BUILD_DIR=~/oc/grades-cordova/platforms/ios/build/emulator,SHARED_PRECOMPS_DIR=~/oc/grades-cordova/platforms/ios/build/sharedpch
Any ideas?

Having <icon> in config.xml breaks the hook/after_prepare/010_add_platform_class.js script.
<platform name="ios">
    <icon src="resources/ios/icon/icon.png" width="57" height="57"/>
   ...
</platform>

The path should be /Users/me/dev/myapp/resources/ios/icon/icon-60.png without config.xml.
cp: no such file or directory: /Users/me/dev/myapp/config.xml/resources/ios/icon/icon-60.png

I noticed in my platform directory, the xcode project name is called Hello Cordova.xcodeproj instead of my actual project name.  It's weird and I don't know how the name is picked up.

Use ionic platform add<EMAIL_ADDRESS>to solve the <icon> issue, but it doesn't solve the incorrect project name.  The xcode project is still called Hello Cordova.xcodeproj.  I'm guessing ionic platform add<EMAIL_ADDRESS>forgets to send the project name to the underlined cordova create.

The first cordova platform add<EMAIL_ADDRESS>uses Hello Cordova.xcodeproj.  I had to run cordova platform rm ios and then run cordova platform add<EMAIL_ADDRESS>again in order to have the correct xcode project name right.  Very strange.

Thanks @5amfung!!!
It helped me.

cordova-plugin-wkwebview-engine breaks Cordova iOS 4.0.0 under iOS 8
https://issues.apache.org/jira/browse/CB-10269

Failed to install local web server, any ideas? thanks!
Failed to install 'cordova-labs-local-webserver':Error: Non-whitespace before first tag.
Line: 0
Column: 1
Char:
at error (C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\node_modules\sax\lib\sax.js:347:8)
at strictFail (C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\node_modules\sax\lib\sax.js:364:22)
at Object.write (C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\node_modules\sax\lib\sax.js:603:11)
at XMLParser.feed (C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\node_modules\elementtree\lib\parsers\sax.js:48:15)
at ElementTree.parse (C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\node_modules\elementtree\lib\elementtree.js:271:10)
at Object.parse (C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\node_modules\elementtree\lib\elementtree.js:584:8)
at module.exports (c:\Projects\ionTone\source\vs2015\ndp2016\Client.Cordova.Ionic\plugins\cordova-labs-local-webserver\scripts\after_install.js:35:20)
at runScriptViaModuleLoader (C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\hooks\HooksRunner.js:167:18)
at runScript (C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\hooks\HooksRunner.js:145:16)
at C:\Users\bob\AppData\Roaming\npm\node_modules\cordova\node_modules\cordova-lib\src\hooks\HooksRunner.js:130:20
Error: Non-whitespace before first tag.
Line: 0
Column: 1

Hello! I have just integrated into an existing Ionic2 App and it has extremely lower the resources usage. In simulator (which consumes a little bit more than in real device) it has lower from something like ~100MB of memory usage to ~10MB. The CPU usage has lower too, it remains between ~5% and ~10% normal usage when it was something like ~20% ~25% with UIWebView. The peak when opening the App has also lower from something like ~80% ~90% to ~30%.
Awesome!

Something worth taking a look at is Telerik WKWebView. It does not require iOS@4+. Also it is a one step solution implementing a local-webserver and crash-recovery. As an aside: IBM MobileFirst + ionic requires ios < 4 (and relies on lots of old code :-1: ), so the current proposed solution would not run (I tried and ended up with a build error: No visible @interface for 'xxxx') but the Telerik WKWebView was a drop in solution for me.

@AceLondon The crash-recovery is bad-news I highly recommend turning it off.

Well, it seems we cannot access the local files as medias etc... Plus my Crosswalk app isn't looking the same on WkWebView, why?
Btw, how to be sure WkWebView is on? My servers get
"Mozilla/5.0 (iPhone; CPU iPhone OS 9_3 like Mac OS X) AppleWebKit/601.1.46 (KHTML, like Gecko) Mobile/13E230"
from emulator, is it good?

Looks good so far! But live reload doesn't work anymore. Do you guys have an idea how I could fix it?

Hello all! I am going to close this issue for now as we have moved to https://github.com/driftyco/cordova-plugin-wkwebview-engine. Thanks for using Ioicn!


Add Windows 10 21H2 (Build 10.0.19044) support

If your BC Container Helper is used in Windows 10 build 19044 and then you try to create a new BC Container with New-BcContainer, it tries to get the container for build 10.0.20348. Then it fails because the Docker container build is higher than the Windows build you are using.
I checked it with BCContainerhelper version 2.0.17-dev and I think the check for 19044 build is missing in your scripts.
So I made 7 changes in Get-BestGenericImageName.ps1, New-NavContainer.ps1, New-NavImage.ps1 files for 19044 build and then I was able to download the needed container files, create the BC container, launch it successfully and work in it.
Script changes:
Get-BestGenericImageName.ps1
Overwrite in line 237:
                if ($hostOsVersion.Build -eq 19043 -or $hostOsVersion.Build -eq 19044) {

New-NavContainer.ps1
Add before in line 421:
	elseif ($os.BuildNumber -eq 19044) {
        $hostOs = "21H2"
    }

Add before in line 1040:
	elseif ("$containerOsVersion".StartsWith('10.0.19044.')) {
        $containerOs = "21H2"
    }

Overwrite in line 1201:
    elseif (("$hostOsVersion".StartsWith('10.0.19043.') -or "$hostOsVersion".StartsWith('10.0.19044.')) -and "$containerOsVersion".StartsWith("10.0.19041.")) {

New-NavImage.ps1
Add before in line 104:
	elseif ($os.BuildNumber -eq 19044) {
        $hostOs = "21H2"
    }

Add before in line 314:
            elseif ("$containerOsVersion".StartsWith('10.0.19044.')) {
                $containerOs = "21H1"
            }

Overwrite at line 347:
           elseif (("$hostOsVersion".StartsWith('10.0.19043.') -or "$hostOsVersion".StartsWith('10.0.19044.')) -and "$containerOsVersion".StartsWith("10.0.19041.")) {

Shipped in 2.0.18


Update Docker pull address

Correction to hxe-ua-install-using-docker step 4.

There are conflicts with this file.  Can you please resolve this.

Hi Joshua - do we have any resources handy to help us resolve such conflicts? I'm not sure where to start debugging.

Typically you can use the "Resolve Conflict" button on the pull request in GitHub.  Just remove the incorrect text and re-commit it to the pull request.

Hi Joshua: Looks like the conflicts are resolved now. Thanks.


Performance drop with tensorflow 2.13

Issue type
Performance
Have you reproduced the bug with TensorFlow Nightly?
Yes
Source
binary
TensorFlow version
v2.13.0-rc2-7-g1cb1a030a62 2.13.0
Custom code
Yes
OS platform and distribution
Debian GNU/Linux 12 (bookworm)
Mobile device
No response
Python version
3.9
Bazel version
No response
GCC/compiler version
No response
CUDA/cuDNN version
No response
GPU model and memory
No response
Current behavior?
I notice a big performance drop between tensorflow 2.12 (CPU) and tensorflow 2.13 (CPU). With the last release (and also with tf-nightly '2.14.0-dev20230724') it takes 4 times longer to perform a simple sum. It is between keras inputs though some I am not sure if this is directly related to tensorflow or if it comes from keras.
See code below for a very simple example. Note that this is with tensorflow CPU only.
The timings are:

for tensorflow 2.12.1 + keras 2.12.0: 5.3 s
for tensorflow 2.13.0 + keras 2.13.1: 24 s
for tensorflow 2.14.0-dev20230724 + keras  2.14.0.dev2023072407: 26 s

Standalone code to reproduce the issue
import time

from tensorflow.keras import Input

number_of_executions = 3000

x = Input((1,))
y = Input((1,))

start = time.time()
for i in range(number_of_executions):
    x + y
duration = time.time() - start
print(f"Duration: {duration:.1f}")

Relevant log output
No response

@nhuet I tried to replicate the issue on colab using TF v2.12 and 2.13, could you please have a look at the attached gists and confirm the same?
Thank you!

It seems to show the issue (even though only 3* slower, this is still abnormal)

@nhuet thank you for the quick response
@sachinprasadhs Could you please have a look at this. Thank you!

Hi @grasskin. You are right I should have definitely tried this. And this works very well indeed (even better than keras2.12 + tf 2.12). Here are the new timings:

keras 2.12.0 + tensorflow 2.12.1: 7.8 s
keras 2.13.1 + tensorflow 2.13.0: 24.1 s
keras-core 0.1.3 + tensorflow 2.12.1: 0.4 s
keras-core 0.1.3 + tensorflow 2.13.0: 0.3 s

(and even increasing the number of iteration, there is not noticeable differences between keras-core + tf2.12 or keras-cre + tf2.13)
Thus, the "bug" came from keras 2.13, and the performance is way better with keras-core than with previous keras 2.12.
Thanks a lot!

Hi @nhuet , Thanks for confirming your findings with the keras-core.
I'm glad that keras-core + tensorflow gave the good performance result.
For latest package details, please visit https://pypi.org/project/keras-core/
Feel free to close the issue. Thanks!


Styling of Quiz Preview / Results

previewquiz.html
result.html

Include #26 Edit Question, #27 Remove Question in previewquiz.html.

Done in #68 #69 , will be pushed in next PR to master.


Bump Openlayers to 7.2.2

Please check release notes for relevant changes and fixes.
https://github.com/openlayers/openlayers/releases/tag/v7.2.0

This update should get rid of the multiple readback operations on the canvas for svg icons and associated warnings.


Plans to upgrade Guzzle from 3 to 6?

Hi,
Is there any plans on upgrading this library from Guzzle 3 to Guzzle 6?
Guzzle 3 is very very old and will from my experience not work (at all) with PHP versions newer than 7.0. And the lifetime of PHP 7.0 is coming to it's end quite soon: http://php.net/supported-versions.php
This lib is also the most downloaded geckoboard library on packagist, so it's probably worth upgrading it to work with supported versions of PHP (as of december): https://packagist.org/?query=geckoboard
Unless the project is abandoned, but I don't see any mentions of that (as in huge titles on top of the readme or so).

Confirmed it can not be used in Magento 2.3.1 as this version requires symfony/event-dispatcher 4.1.* whereas guzzle/guzzle requires ~2.1.
I think it's necessary to upgrade to guzzlehttp/guzzle.

Hey @kozie,
To get around this issue I'm running this lib on a private fork for our internal projects at work.
But this is the only patch that is needed:
diff --git a/src/CarlosIO/Geckoboard/Client.php b/src/CarlosIO/Geckoboard/Client.php
index 378cd4a..120e27a 100644
--- a/src/CarlosIO/Geckoboard/Client.php
+++ b/src/CarlosIO/Geckoboard/Client.php
@@ -2,7 +2,8 @@

 namespace CarlosIO\Geckoboard;

-use Guzzle\Http\Client as Guzzle;
+use GuzzleHttp\Client as HttpClient;
+use GuzzleHttp\RequestOptions;
 use CarlosIO\Geckoboard\Widgets\Widget;

 /**
@@ -13,9 +14,9 @@ class Client
     const URI = 'https://push.geckoboard.com';

     /**
-     * @var \Guzzle\Http\Client
+     * @var HttpClient
      */
-    protected $client;
+    protected $httpClient;

     /**
      * @var string
@@ -28,17 +29,19 @@ class Client
     public function __construct()
     {
         $this->api = '';
-        $this->client = new Guzzle(self::URI);
+        $this->httpClient = new HttpClient([
+            'base_uri' => self::URI,
+        ]);
     }

     /**
-     * @param array|\Guzzle\Common\Collection $config
+     * @param array $config
      *
      * @return Client $this
      */
-    public function setGuzzleConfig($config)
+    public function setGuzzleConfig(array $config)
     {
-        $this->client->setConfig($config);
+        $this->httpClient = new HttpClient($config);

         return $this;
     }
@@ -46,11 +49,11 @@ public function setGuzzleConfig($config)
     /**
      * @param string|bool $key
      *
-     * @return \Guzzle\Common\Collection|mixed
+     * @return mixed
      */
     public function getGuzzleConfig($key = false)
     {
-        return $this->client->getConfig($key);
+        return $this->httpClient->getConfig($key);
     }

     /**
@@ -123,14 +126,14 @@ private function pushWidgets($widgets)
      */
     private function pushWidget(Widget $widget)
     {
-        $this->client->post(
+        $this->httpClient->post(
             '/v1/send/'.$widget->getId(),
-            null,
-            json_encode(
-                array(
+            [
+                RequestOptions::JSON => [
                     'api_key' => $this->getApiKey(),
                     'data' => $widget->getData(),
-                )
-            ))->send();
+                ]
+            ]
+        );
     }
 }

Plus obviously changing the composer.json to depend on a newer guzzle (I'm running it on guzzle 6.3.3).
This change also broke a test but yeah, for a monkeypatch I didn't care to much about that.

Awesome, @etu !
Thanks for sorting out and sharing the patch! :)


Repl cursor at position 0 is cropped

Notice how the top-left corner of the cursor is cropped by a single pixel:

This might be the hidden text area.

Thanks for the tip that it is the hidden text area, though dup of https://github.com/Microsoft/vscode/issues/13067


Installer: [SPIKE] use Astilectron in PoC

Feature Request
Add in the mechanism to execute Go code (especially an OSExec call) to the PoC installer.

Closing as won't implement. An alternative solution will be used when creating the TCE installer.


Draft Principles page content

Create content for the Principles page for the Design System website.
Google Doc for drafting content

@wrendo Only a couple of loose items to tie down and we can call the Principles page locked.
Item 1: Adam called out the "eyebrow headers" that are Principle [#]. I like each principle being an H2 on the page. That would make these numbered preceding headers tricky if we cascade headers cascade properly. Here are solutions that use a single line, pulling the number into the H2:

Principle 1: Design for people's needs
#1: Design for people's needs

I'm open to other ideas to achieve the design Adam suggested. There might be something I haven't thought of. 🙂
Item 2: Any final tweaks to the content itself?

Google Doc where I'm editing
Figma where Adam's mocked it up

Love the first example you gave. Let's run it by @adam-little
Can't think of anymore tweaks off the top of my head

Since the developers already gave the green light to the custom design, I would prefer to keep it because it adds visual variety to the page.
We can talk about semantics separately. Just because the eyebrow sits above the principle title visually doesn't necessarily mean it has to semantically.

Sounds good. We can iterate on that post launch if need be. Maybe we can spin off a mini issue on this to revisit.

Adam and I discussed on Slack and I too am OK with this organization (helpfully made concise by Adam!):

[h1] Principles
[h2] Principle #
[h3] Principle title
[p] Principle description

With that settled, this content is done on my end. Any final review you want for it @wrendo ? If not, does that mean this issue is closed?

Closed!


Add an author data item to tools

Tools donated by other people should show recognition for them.

and/or preferences options (like themes can show different themes from different users.

Added tool preference author in v2.0.33. Themes will have to be handled separately.


Template substitution errors

I installed Eigen 3.3.1 and when I wanted to try out the code in this section, it threw the errors attached. I used g++ -std=c++11 code.cpp, where code.cpp is the code from the cited section and the Eigen folder is placed in the main directory.
errorMessage.txt

Looks like something to do with complex values, a capability that was added after I wrote that example code. I'll look into it.

I had no errors with this code using Eigen 3.2.9, but after updating to Eigen 3.3.3 I got an error based on the return type of log(), which is different than the errors you mention (maybe specific to version 3.3.1?). I updated EigenLab.h to handle this, so now the command line program as in the README (I also added a CmdLine.cpp file to tests/) works for me with Eigen 3.3.3.


GEOMESA-1114 Off by one errors in GridSnap

Use BigDecimal for dx and dy
Properly compute dx and dy

Signed-off-by: Anthony Fox<EMAIL_ADDRESS>

2d5d231..4b70646


Auto-link _space applications in base/urls.py

(based on the presence of installed applications in memex.settings)

Current method to auto-include: discover "_space" containing applications registered in settings.INSTALLED_APPS, and include those urls with a project slug prefix.
A better implementation would add applications listed under apps to INSTALLED_APPS.

Apps are registered in settings.EXPLORER_APPS: https://github.com/ContinuumIO/memex-explorer/commit/902282d2f4289ecc737a7f16445e6f3677f39d54


Adding bower.json file. Fixes #361.

As per #361, this adds a basic bower.json file.
Might I also suggest using Bower for dependency management in general? This would involve adding a .bowerrc file saying to use vendor instead of bower_components, and rewriting the examples to point to something like /vendor/d3/d3.js instead.

Adding this lib to bower would be a huge benefit. I would love to see this PR accepted.

+1 for Bower dependencies.

+1

:+1:

+1

Bower is dead! Long live npm! :tada:


In small viewports the tag "Hide deprecated" gets cut off when being selected. I'm pretty sure this is a regression from https://github.com/apple/swift-docc-render/pull/

In small viewports the tag "Hide deprecated" gets cut off when being selected. I'm pretty sure this is a regression from https://github.com/apple/swift-docc-render/pull/291

Do you want to fix it in this radar or want me to create a new one?

When adding an input to filter input after selecting the "Hide deprecated" tags, the matching children don't get opened, is this intended? I thought we would keep it closed only when there was no input added.

Originally posted by @JCDiana in https://github.com/apple/swift-docc-render/pull/331#issuecomment-1141408547

We have fixed these issues in the PR. The cutoff tag is expected.


The ride request is always processing

Polling the Uber API to get the current status every 4 seconds,I always get the response :
{      “status":"processing",      "product_id":"...",      "request_id":"...",      "driver":null,      "eta":null,      "location":null,      "vehicle":null,      "surge_multiplier":1.0,      "shared":false}
The status is always processing. I failed to solve it . Can you help me ?

I think you might be running the service in a sandbox environment.  When this is the case, you have to manually make changes to your ride's status via RidesService#updateSandboxRide method, as detailed in the Rides Java SDK's README as well as the developer documentation.
For example, you can try updating your sandbox ride with
SandboxRideRequestParameters rideParameters = new SandboxRideRequestParameters.Builder().setStatus(“accepted”).build(); Response<Void> response = service.updateSandboxRide(rideId, rideParameters).execute();
Please let me know if you're still having any issues!  If you don't want to run in the sandbox, set the environment to PRODUCTION in your SessionConfiguration

Thank you for you help.I have solved it.


error

File "C:\Users\Ivan\termatus\termatus\main.py", line 427, in
with Live(renderable=base(information_dictionary=basic_info(),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Ivan\termatus\termatus\main.py", line 271, in base
f"\n{cleaned_net_info[0]}\narea: {cleaned_net_info[1].split(': ')[1]}, {cleaned_net_info[2].split(': ')[1]}, {cleaned_net_info[3].split(': ')[1]}\nISP: {cleaned_net_info[6].split(': ')[1]}",
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~^^^
IndexError: list index out of range

i think this part requires an internet connection in order to get the
required details. did you check your net? do tell if any other problems
occur
On Fri, Jul 19, 2024 at 2:01 AM axalight @.***> wrote:

File "C:\Users\Ivan\termatus\termatus\main.py", line 427, in
with Live(renderable=base(information_dictionary=basic_info(),
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\Ivan\termatus\termatus\main.py", line 271, in base
f"\n{cleaned_net_info[0]}\narea: {cleaned_net_info[1].split(': ')[1]},
{cleaned_net_info[2].split(': ')[1]}, {cleaned_net_info[3].split(':
')[1]}\nISP: {cleaned_net_info[6].split(': ')[1]}",
IndexError: list index out of range

—
Reply to this email directly, view it on GitHub
<https://github.com/muaaz-ur-habibi/termatus/issues/1>, or unsubscribe
<https://github.com/notifications/unsubscribe-auth/BEJZUAYSTQIM3ECVWE4WZGDZNAULFAVCNFSM6AAAAABLDNMWFSVHI2DSMVQWIX3LMV43ASLTON2WKOZSGQYTOMZZGI4DGNA>
.
You are receiving this because you are subscribed to this thread.Message
ID<EMAIL_ADDRESS>


[WIP] Implement 1D to ND interpolation

[x] Closes #3252
[ ] Tests added
[ ] Passes black . && mypy . && flake8
[ ] Fully documented, including whats-new.rst for all changes and api.rst for new API

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

In the file xarray/tests/test_interp.py:

Line 670:5: F841 local variable 'old_coord' is assigned to but never used
Line 676:36: E226 missing whitespace around arithmetic operator
Line 676:51: E226 missing whitespace around arithmetic operator
Line 679:21: E226 missing whitespace around arithmetic operator
Line 693:31: E231 missing whitespace after ','
Line 711:1: F811 redefinition of unused 'test_interp_1d_nd_targ' from line 704
Line 718:1: E302 expected 2 blank lines, found 1
Line 729:1: W391 blank line at end of file

For highly optimized interpolation of an N-dimensional array along any one dimension, see also https://xarray-extras.readthedocs.io/en/latest/api/interpolate.html

One missing part of the algorithm I wrote in https://github.com/pydata/xarray/pull/3262#issuecomment-525154116 was looping over all index/weight combinations. I recently wrote a version of this for another project that might be a good starting point here:
def prod(items):
  out = 1
  for item in items:
    out *= item
  return out

def index_by_linear_interpolation(array, float_indices):
  all_indices_and_weights = []
  for origin in float_indices:
    lower = np.floor(origin)
    upper = np.ceil(origin)
    l_index = xlower.astype(np.int32)
    u_index = upper.astype(np.int32)
    l_weight = origin - lower
    u_weight = 1 - l_weight
    all_indices_and_weights.append(
        ((l_index, l_weight), (u_index, u_weight))
    )

  out = 0
  for items in itertools.product(*all_indices_and_weights):
    indices, weights = zip(*items)
    indices = tuple(index % size for index, size in zip(indices, array.shape))
    out += prod(weights) * array[indices]
  return out

Unfortunately, I don’t think I have much time now to contribute to a general purpose solution leveraging xarray’s built-in indexing. So feel free to add to or close this PR. To be successful, I would need to study xarray’s indexing internals more since I don’t think it is as easily implemented as a routine calling DataArray methods. Some custom numba code I wrote fits in my brain much better, and is general enough for my purposes when wrapped with xr.apply_ufunc. I encourage someone else to pick up where I left off, or we could close this PR.

No worries! You were a great help already!
On Sat, Nov 2, 2019 at 3:01 PM Noah D Brenowitz<EMAIL_ADDRESS>wrote:

Unfortunately, I don’t think I have much time now to contribute to a
general purpose solution leveraging xarray’s built-in indexing. So feel
free to add to or close this PR. To be successful, I would need to study
xarray’s indexing internals more since I don’t think it is as easily
implemented as a routine calling DataArray methods. Some custom numba code
I wrote fits in my brain much better, and is general enough for my purposes
when wrapped with xr.apply_ufunc. I encourage someone else to pick up
where I left off, or we could close this PR.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
https://github.com/pydata/xarray/pull/3262?email_source=notifications&email_token=AAJJFVQEA7HP77G2FKRYYATQRX2CPA5CNFSM4IPHIIXKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEC5F7HI#issuecomment-549085085,
or unsubscribe
https://github.com/notifications/unsubscribe-auth/AAJJFVXSUO5GOMC67PPGBGDQRX2CPANCNFSM4IPHIIXA
.

I'm going to close this since I won't be working on it any longer.


Added code syntax highlighting to Readme

This now conflicts.
Please rebase your changes and update the pull request.

I still see conflicts.


Large number of ATNConfig objects in heap

We've seen heap dumps with 22+ million ATNConfig objects, which appeared to be stored in Antlr's cache. We should investigate whether this is a bug, or an issue with the complexity of our grammar

http://stackoverflow.com/questions/28017135/why-antlr4-parsers-accumulates-atnconfig-objects
We might have to call Recognizer.clearDFA() periodically
4th comment seems to refer https://groups.google.com/forum/#!topic/antlr-discussion/8Yu-Tdh4gq4

I try calling clearDFA as a workaround https://github.com/miniway/presto/commit/44b9ac34196db6d01e99ecc0fbad33f92ba1eb40


Update README.md

fixing duplicate upgrade command in "sudo apt upgrade && sudo apt upgrade"

good catch on typo!


KOGITO-1392: CSS tweaks

Task
https://issues.redhat.com/browse/KOGITO-1392
Description
Added the features 1, 2 and 5 from https://marvelapp.com/8a8h595/screen/67998289

I'd have liked the changes for this to be made after https://github.com/kiegroup/kogito-tooling/pull/142 was merged (rather selfishly really, as it'll make my life easier!) If that's not possible can you please make sure there is enough test coverage on this PR to be sure my changes do not break anything (my PR moves desktop, online and github channels all to use a single reusable "embedded" editor and it touches some of the classes you  change here).

Hi @manstis ! I've already removed some features of this PR because was decided to break it on another task. I believe it's not going to have any conflict now.

Thanks @ljmotta it looks plain sailing now.

@srambach I've removed the magic numbers and fixed the title shift! I hope it's OK the new value I've chosen for the padding.

The padding on the title element looks good now 👍 and spacer variables FTW 😆

Check on browser:

[ ] chrome
[ ] firefox


Unhandled rejection Configuration file could not be found: config/config.json

Evidence
Using Webpack  following the step by step documentation creating the folder "config" in the root I get the webpack error ...
GET http://localhost:8080/config/config.json 404 (Not Found)
aurelia-configuration.js?35ae:208
Unhandled rejection Configuration file could not be found: config/config.json
bluebird.js?f684:1564
Is there any solution involving this problem?

Same here!

Just for future reference, It's trying to look within {rootFolder}/dist/config/config.json

Create a folder within static called config and create config.json


[top_earlgrey] Create bitstreams with failing timing

We currently check for timing failures before creating a bitstream,
which is a good thing (TM). However, currently the FPGA design fails
timing. To buy us time investigating the best mitigation for that we
allow the design to fail timing.
Tracked in #2508

Works, the slack error is now a warning.


Prepackage hooks runs after building the docker image

Description
The first deployment fails (obviously as the static folder was not included in the docker image)

After deploying again the website works (as the static folder is already there from the first deployment)
Proposal
Is this an azd failure or do we understand the service lifecycle wrong?
The frontend build step is in the prepackage stage yet it happens after building the docker image.

Move this issue to azd? Done
Add instructions for manually building the frontend before running azd?

So Wallace Breza says that this should be a prebuild hook not prepackage but let's see what he will say on the issue.
Changing the step from prepackage to prebuild should resolve this issue.
https://github.com/Azure/azure-dev/issues/3546#issuecomment-2005003062

Huh, thanks for raising that with them. Let's change to prebuild then.

FYI this needs to be done for all of the samples that has a "build" stage in their lifecycle where it builds a docker image.
Any sample with ACA that has prepackage command that runs frontend build needs to be changed to prebuild


./gradlew cAT failed in sample

You have no CI support, so I did a test run locally with ./gradlew cAT
But it fails with
> Task :android:connectedDebugAndroidTest
Starting 2 tests on API_30_Google_Api(AVD) - 11

io.github.usefulnes.testing.screenshot.sample.ScreenshotsSampleActivityTest > testScreenshotEntireActivityWithoutAccessibilityMetadata[API_30_Google_Api(AVD) - 11] FAILED
        java.lang.RuntimeException: Failed to create the directory /sdcard/screenshots/io.github.usefulness.testing.screenshot.sample.test/screenshots-default for screenshots. Is your sdcard directory read-only?
        at com.facebook.testing.screenshot.internal.ScreenshotDirectories.getSdcardDir(ScreenshotDirectories.java:119)

io.github.usefulnes.testing.screenshot.sample.ScreenshotsSampleActivityTest > testScreenshotEntireActivity[API_30_Google_Api(AVD) - 11] FAILED
        java.lang.RuntimeException: Failed to create the directory /sdcard/screenshots/io.github.usefulness.testing.screenshot.sample.test/screenshots-default for screenshots. Is your sdcard directory read-only?
        at com.facebook.testing.screenshot.internal.ScreenshotDirectories.getSdcardDir(ScreenshotDirectories.java:119)
Tests on API_30_Google_Api(AVD) - 11 failed: There was 2 failure(s).

> Task :android:connectedDebugAndroidTest FAILED

The library has exactly the same limitations as the original and it seems like you hit this: https://github.com/facebook/screenshot-tests-for-android/issues/224#issuecomment-501072359
You have to do the same as the CI pipeline does:
https://github.com/usefulness/screenshot-tests-for-android/blob/73f619fb9c230e13a21d6c49d09731f962616dc8/.github/workflows/pull_request.yml#L160-L162
I hope this helps 🤞

I didn't see that it's a fork. Anyway, thank you !
Btw, this looks very promising https://github.com/android/testing-samples/tree/main/ui/espresso/ScreenshotSample.
It's super fast, but I've to figure out, where the images are stored to be able to grab it from device

Here they are ! It's so easy

Great! I'm happy this works for you as well 🎉
This is indeed a fork of https://github.com/facebook/screenshot-tests-for-android which I had to detach to be able to publish under my own credentials on mavencentral 🤷 The difference in features is this supports Gradle Configuration Cache (https://github.com/facebook/screenshot-tests-for-android/issues/307)
if you're looking for some guidance, I recommend reading their documentation: https://facebook.github.io/screenshot-tests-for-android/#getting-started
However, if you're just considering to add screenshot testing, then I'd probably recommend using a different library: https://github.com/pedrovgs/Shot or even https://github.com/cashapp/paparazzi.
This, while being maintained, has a couple of design flaws that make it non-ideal for long term projects :)


Update azure-stack-enable-multitenancy.md

This seems like a small (but important) contribution, so no Contribution License Agreement is required at this point. We will now review your pull request.
Thanks,
Microsoft Pull Request Bot

@RedBa : Thanks for your contribution to the Azure documentation! The author, @HeathL17, has been notified to review your proposed change.

Thanks, good catch @RedBa!  #sign-off.


Update LRO client with latest toolkit

@garrettjonesgoogle @michaelbausor PTAL

Codecov Report

Merging #217 into master will decrease coverage by -0.05%.
The diff coverage is 40%.

@@             Coverage Diff             @@
##             master    #217      +/-   ##
===========================================
- Coverage     70.25%   70.2%   -0.05%
  Complexity      483     483
===========================================
  Files            67      67
  Lines          2538    2541       +3
  Branches        266     267       +1
===========================================
+ Hits           1783    1784       +1
- Misses          657     659       +2
  Partials         98      98

Impacted Files
Coverage Δ
Complexity Δ

...ava/com/google/longrunning/OperationsSettings.java
75% <40%> (-1.24%)
7 <0> (ø)

Continue to review full report at Codecov.

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

LGTM


Generate a JSON file with the last structures of all ISI

Feature request
Generate a JSON file containing the last examples structures of all existing ISI instructions from the code located at core/src/smartcontracts/isi/ for testing purposes, similar to the genesis.json?
Motivation
I require this to construct user's instructions that have not yet been added to the client_cli.
Who can help?
@astrokov7

@astrokov7
#3398 adds a new subcommand to kagami that you can pipe to iroha_client_cli.
./kagami examples create-account --account-id "test123@wonderland" | ./iroha_client_cli json

This feature should help you to reproduce use cases from these tests


Error when trying to migrate using git+ssh url

Gitea version (or commit ref): 1.3.0 and whatever is on try.gitea.io
Can you reproduce the bug at https://try.gitea.io:

[X] Yes (screenshot was done at try.gitea.io)
[ ] No
[ ] Not relevant

changing "Migration type" doesn't matter
using alternative git url like<EMAIL_ADDRESS>doesn't help. Doing it via HTTPS works but that is not exactly ideal as not every repo migrated from will be accessible via https

SSH currently not supported.

@XANi see issue #1635 for tips on migrating using Git.
Also if you want to use SSH you will have to set the SSH/GPG keys in the user menu.
On Windows 10 I also had to copy the SSH* utilities from the Git directory to the Gitea directory, adding to the PATH did not work.
More info on SSH here: https://help.github.com/articles/connecting-to-github-with-ssh/

Is there a solution?

duplicated with #1635


cleanup(pubsub): save a copy

https://github.com/googleapis/google-cloud-cpp/pull/13152/files#r1399485848

This change is

Missed the comment, thanks for making the fix.


Allow for unicode strings to be passed as regex filters when selectin…

…g which columns to read.
was previously failing with Python 2.7 when were passing u'some_field.*'.

Approved assuming Travis build succeeds.


[Request]: Bump mime to v2

Plugin
share_plus
Use case
share_plus is preventing us from upgrading our packages:
flutter pub upgrade --major-versions

Because every version of <some_package> from git depends on mime ^2.0.0 and share_plus >=7.0.0 depends on mime ^1.0.4, <some_package> from git is incompatible with share_plus >=7.0.0.

Proposal
Bump mime from share_plus to v2

Feel free to submit a PR with the upgrade. This should have been upgraded by dependabot but it did not appear yet.
Also you can use dependency overrides, so nothing is blocking you.

@miquelbeltran merged PR last week. So, we'll have to wait for the release.
https://github.com/fluttercommunity/plus_plugins/pull/3288

Since image_picker (for web) uses mime v1, so we cannot use v2 for now for share_plus.

Ah I see it was increased for platform interface but not for the main package.
Looking at the changeling I saw one method now can return null, so I need to verify if that can cause an issue.

I am taking the PR you opened and I am changing it so:

mime is set to a range that includes both v1 and v2, so it is backwards compatible
checks for null return of extensionFromMime

@miquelbeltran thank you!


[composer] cannot drag an item back to a space it originated from

composer staging 0.3.7 candidate:
drag a document from space A to space B: success
drag it back: fail.

Mitigated for now by #5627


NF and NX, failing to resolve import of libraries

I'm trying to migrate my NX project to utilize native federation and I'm struggling to get the library imports to work.
Here is the error I'm getting when serving one of the microfrontends
 INFO  Building federation artefacts

Initial Chunk Files      | Names         |  Raw Size
styles.css               | styles        | 195.17 kB |
polyfills.js             | polyfills     | 178.81 kB |
main.js                  | main          | 292 bytes |

                         | Initial Total | 374.26 kB

Lazy Chunk Files         | Names         |  Raw Size
bootstrap-PZCGXKON.js    | bootstrap     |   2.60 kB |
entry.module-NE57NXWG.js | entry-module  |   1.96 kB |

Application bundle generation complete. [4.844 seconds]
Watch mode enabled. Watching for file changes...
Failed to resolve dependency: @xyz/branding-main, present in 'optimizeDeps.include'
Failed to resolve dependency: @xyz/branding/feature-brander, present in 'optimizeDeps.include'
Failed to resolve dependency: @xyz/shared/util-branding-config, present in 'optimizeDeps.include'
Failed to resolve dependency: @xyz/shared/util-translation-config, present in 'optimizeDeps.include'
  ➜  Local:   http://localhost:4203/
9:09:52 AM [vite] Internal server error: Failed to resolve import "@xyz/shared/util-branding-config" from ".angular/vite-root/branding/bootstrap-PZCGXKON.js". Does the file exist?
  Plugin: vite:import-analysis
  File: /home/vagrant/dev/hub-frontend/.angular/vite-root/branding/bootstrap-PZCGXKON.js:1:47
  4  |
  5  |  // apps/branding/src/app/app.module.ts
  6  |  import { SharedUtilBrandingConfigModule } from "@xyz/shared/util-branding-config";
     |                                                  ^
  7  |  import { SharedUtilTranslationConfigModule } from "@xyz/shared/util-translation-config";
  8  |  import { BrowserAnimationsModule } from "@angular/platform-browser/animations";
      at formatError (file:///home/vagrant/dev/hub-frontend/node_modules/vite/dist/node/chunks/dep-68d1a114.js:44062:46)
      at TransformContext.error (file:///home/vagrant/dev/hub-frontend/node_modules/vite/dist/node/chunks/dep-68d1a114.js:44058:19)
      at normalizeUrl (file:///home/vagrant/dev/hub-frontend/node_modules/vite/dist/node/chunks/dep-68d1a114.js:41844:33)
      at process.processTicksAndRejections (node:internal/process/task_queues:95:5)
      at async file:///home/vagrant/dev/hub-frontend/node_modules/vite/dist/node/chunks/dep-68d1a114.js:41998:47
      at async Promise.all (index 2)
      at async TransformContext.transform (file:///home/vagrant/dev/hub-frontend/node_modules/vite/dist/node/chunks/dep-68d1a114.js:41914:13)
      at async Object.transform (file:///home/vagrant/dev/hub-frontend/node_modules/vite/dist/node/chunks/dep-68d1a114.js:44352:30)
      at async loadAndTransform (file:///home/vagrant/dev/hub-frontend/node_modules/vite/dist/node/chunks/dep-68d1a114.js:55026:29)
      at async viteTransformMiddleware (file:///home/vagrant/dev/hub-frontend/node_modules/vite/dist/node/chunks/dep-68d1a114.js:64430:32)

I'm not exactly sure where to look to resolve this, but here are the contents of some of the files that I think matter:
federation.config.ts
const {
  withNativeFederation,
  shareAll,
} = require('@angular-architects/native-federation/config');

module.exports = withNativeFederation({
  name: 'branding',

  exposes: {
    './Component': './apps/branding/src/app/app.component.ts',
    './Module': './apps/branding/src/app/app.module.ts',
  },

  shared: {
    ...shareAll({
      singleton: true,
      strictVersion: true,
      requiredVersion: 'auto',
    }),
  },

  skip: [
    'rxjs/ajax',
    'rxjs/fetch',
    'rxjs/testing',
    'rxjs/webSocket',
    // Add further packages you don't need at runtime
  ],
});

tsconfig.base.json
{
  "compileOnSave": true,
  "compilerOptions": {
    "rootDir": ".",
    "sourceMap": true,
    "declaration": false,
    "moduleResolution": "node",
    "resolveJsonModule": true,
    "allowSyntheticDefaultImports": true,
    "emitDecoratorMetadata": true,
    "experimentalDecorators": true,
    "importHelpers": true,
    "target": "ES2022",
    "module": "ES2022",
    "lib": ["ES2022", "dom"],
    "skipLibCheck": true,
    "skipDefaultLibCheck": true,
    "baseUrl": ".",
    "paths": {
      "@xyz/branding-main": ["libs/branding/main/src/index.ts"],
      "@xyz/branding/feature-brander": [
        "libs/branding/feature-brander/src/index.ts"
      ],
      "@xyz/shared/util-branding-config": [
        "libs/shared/util-branding-config/src/index.ts"
      ],
      "@xyz/shared/util-translation-config": [
        "libs/shared/util-translation-config/src/index.ts"
      ]
    }
  },
  "exclude": ["node_modules", "tmp"]
}

I'm using version 17.1.0 of the native federation library.
Any help would be appreciated!

I think the issue was that I was using angular v17.0.x. Once I upgraded to v17.1.1 it worked!


About the size of the model?

Hi,
Thanks to your amazing work!
I want to test your model in my own data, but it always out of memory, even if I try it on GTX 1080Ti. So I want to know the graphics card you use in your experiment.

Hi, thank you so much for testing our code.
For the dataset used in the RL-Restore paper, we used two GTX 1080Ti GPUs. Also, we used four GTX 1080Ti GPUs for our own dataset used in our paper.


Use upstream instances for Arbitrary SlotNo

Description
Depends on input-output-hk/cardano-base#447.
Needed for input-output-hk/ouroboros-consensus#517
Needs rebase once the cardano-base packages are on CHaP.
Checklist

Branch

[ ] Updated changelog files.
[ ] Commit sequence broadly makes sense
[ ] Commits have useful messages
[ ] The documentation has been properly updated
[ ] New tests are added if needed and existing tests are updated
[ ] If serialization changes, user-facing consequences (e.g. replay from genesis) are confirmed to be intentional.

Pull Request

[ ] Self-reviewed the diff
[ ] Useful pull request description at least containing the following information:

What does this PR change?
Why these changes were needed?
How does this affect downstream repositories and/or end-users?
Which ticket does this PR close (if any)? If it does, is it linked?

[ ] Reviewer requested

I'll approve when the dependencies get on CHaP and the SRP are removed 😄

Wise choice 😌

Ready to review @bolt12 😄


Mspsds 486 protect search results from companies house outages

Pull Request Test Coverage Report for Build 592

0 of 0   changed or added relevant lines in 0 files are covered.
13 unchanged lines in 2 files lost coverage.
Overall coverage decreased (-0.6%) to 85.49%

Files with Coverage Reduction
New Missed Lines
%

../helpers/businesses_helper.rb
4
92.98%

../clients/companies_house_client.rb
9
66.67%

Totals

Change from base Build 590:
-0.6%

Covered Lines:
925

Relevant Lines:
1082

💛  - Coveralls


python: infer fs/se mode from workload for boards with both

This commit modifies abstract_board.py so that boards that support both SE and FS mode (have both set_se_binary_workload and set_kernel_disk_workload) can infer which to use based on the workload that is set.

Could you move both self._self_board() and self._setup_memory_ranges() from the __init__ and put them both as called above connect_things in the _pre_instantiate function(i.e., the first things called in that function)?

I tried doing this but got the following error:
AttributeError: Class StubWorkload has no parameter object_file

At:
  /home/bees/gem5-2nd-worktree/src/python/m5/SimObject.py(922): __setattr__
  /home/bees/gem5-2nd-worktree/src/python/gem5/components/boards/kernel_disk_workload.py(191): set_kernel_disk_workload
  /home/bees/gem5-2nd-worktree/src/python/gem5/components/boards/abstract_board.py(242): set_workload
  ../x86-ubuntu-run-with-kvm-no-perf.py(126): <module>
  /home/bees/gem5-2nd-worktree/src/python/m5/main.py(675): main

Could you move both self._self_board() and self._setup_memory_ranges() from the __init__ and put them both as called above connect_things in the _pre_instantiate function(i.e., the first things called in that function)?

I tried doing this but got the following error:
AttributeError: Class StubWorkload has no parameter object_file

At:
  /home/bees/gem5-2nd-worktree/src/python/m5/SimObject.py(922): __setattr__
  /home/bees/gem5-2nd-worktree/src/python/gem5/components/boards/kernel_disk_workload.py(191): set_kernel_disk_workload
  /home/bees/gem5-2nd-worktree/src/python/gem5/components/boards/abstract_board.py(242): set_workload
  ../x86-ubuntu-run-with-kvm-no-perf.py(126): <module>
  /home/bees/gem5-2nd-worktree/src/python/m5/main.py(675): main

Could you move both self._self_board() and self._setup_memory_ranges() from the __init__ and put them both as called above connect_things in the _pre_instantiate function(i.e., the first things called in that function)?

I tried doing this but got the following error:
AttributeError: Class StubWorkload has no parameter object_file

At:
  /home/bees/gem5-2nd-worktree/src/python/m5/SimObject.py(922): __setattr__
  /home/bees/gem5-2nd-worktree/src/python/gem5/components/boards/kernel_disk_workload.py(191): set_kernel_disk_workload
  /home/bees/gem5-2nd-worktree/src/python/gem5/components/boards/abstract_board.py(242): set_workload
  ../x86-ubuntu-run-with-kvm-no-perf.py(126): <module>
  /home/bees/gem5-2nd-worktree/src/python/m5/main.py(675): main

Could you move both self._self_board() and self._setup_memory_ranges() from the __init__ and put them both as called above connect_things in the _pre_instantiate function(i.e., the first things called in that function)?

I tried doing this but got the following error:
AttributeError: Class StubWorkload has no parameter object_file

At:
  /home/bees/gem5-2nd-worktree/src/python/m5/SimObject.py(922): __setattr__
  /home/bees/gem5-2nd-worktree/src/python/gem5/components/boards/kernel_disk_workload.py(191): set_kernel_disk_workload
  /home/bees/gem5-2nd-worktree/src/python/gem5/components/boards/abstract_board.py(242): set_workload
  ../x86-ubuntu-run-with-kvm-no-perf.py(126): <module>
  /home/bees/gem5-2nd-worktree/src/python/m5/main.py(675): main

Ok, almost there. Keep this change I suggest but, in addition, move the self.workload = RiscvBootloaderKernelWorkload() from your _setup_board function and put it in the _set_fullsystem function. In _set_fullsystem have it so this self.workload = ... is run only when fs=True.
Every board (I think) has a similar setup. That is, self.workload set in _setup_board go through each and do this in each case.
I think once you've done that things will work. If not, can you upload your changes here so I can look at them?

I was able to get X86Board to work by moving an an additional line from _setup_board into _set_fullsystem. For ArmBoard, RiscvBoard, and RISCVMatchedBoard, it seemed like the majority or entirety of _setup_board would have to be moved into _set_fullsystem before it would work.

@erin-le : Why was this closed? Perhaps you mentioned it in person but I don't remember the reason.
You said this was needed before #1618 was merged so i'm guessing we need to reopen this, right?

We were trying to get the number of open PRs I had down to zero so I could delete the fork of gem5 I'm currently using and get a new fork directly from gem5/gem5. I closed this PR since the last few messages were just to show you the changes that didn't work.

I think last commit in PR #1497 does what we want. Can you look it over and find out if this works and is compatible with the DemoBoards or if it's missing anything we may need?


edge support issue(s)

All of the css filters are not working.

Also it looks like we are not getting pointer move events?

Looks like firefox mobile has similar issues
https://twitter.com/_bwhitty/status/872507963876954112
cc @jasonlaster

https://developer.microsoft.com/en-us/microsoft-edge/platform/issues/12266664/

Looks like firefox mobile is also not formatting numbers correctly.

https://twitter.com/KhaledElAnsari/status/872854645382819840

It's also pretty janky on Firefox Mobile on a top of the range Moto Z https://twitter.com/stowball/status/873480291712618496

Also it looks like we are not getting pointer move events?

How do you mean? is USE_POINTER_EVENTS false? do you see green or red here?


Trans

Adding new transport package to start building a beautiful terminal wrapper
Closes #35
Closes #32
Closes #28

Best PR.


feat: add function to get visible state

Changes according to https://github.com/tris203/precognition.nvim/pull/80#issuecomment-2248127414
Closes #80

Thanks!


t2 erase doesn't exit

Output:
➜  pir git:(master) t2 erase
INFO Connecting to Tessel...
INFO Connected to Kelsey over LAN
INFO Erasing files from Flash...
INFO Files erased.

then it just hangs

I've fixed this in a local branch. PR coming soon.

Will be fixed in #215.


Light weight version of arc-circom

Hi, @gakonst!
In case you are still willing to make a trimmed version of ark-circom ( https://github.com/vacp2p/zerokit/issues/37#issuecomment-1252699994 )
we would greatly appreciate if you could make one without the ethers-core/ethers-rs dependencies like here ( https://github.com/vacp2p/ark-circom/tree/no-ethers-core ) since we don't need them in zerokit and are actively trying to make our binaries smaller.

https://github.com/gakonst/ark-circom/pull/41

Has this been resolved by #41 already?


tf.split

Missing API: tf.split
https://www.tensorflow.org/versions/r1.15/api_docs/python/tf/split

Our functions are generally generated. If you can't find it in tf.* then it is likely to be in other place.

In this case in gen_array_ops and gen_ops.
@Oceania2018 An alias in tf namespace will be enought.

thank you so much!

@Jamaslab It's relatively easy to add. Appreciate if you can PR.

Yep will do ASAP

Added in PR #408


Implement In-Game Singleton

[x] Singleton
[x] Local Source
[x] 2D UI Example

All items are implemented, they just need some mild debugging


Sharepoint 2016 on server 2016 pre-reqs wont install

Need to follow this solution http://www.mim.ninja/2018/11/06/mim-2016-deployment-on-windows-2016-application-server-deprecated/

Document Details
⚠ Do not edit this section. It is required for docs.microsoft.com ➟ GitHub issue linking.

ID: 1bb5efc7-7c39-cf26-70ef-a324d215af76
Version Independent ID: add2ba42-a910-ce5f-3767-35834085c2fa
Content: Configure SharePoint for Microsoft Identity Manager 2016
Content Source: MIMDocs/prepare-server-sharepoint.md
Product: microsoft-identity-manager
GitHub Login: @billmath
Microsoft Alias: billmath

If you mean by won't install that you get download errors, try disabling the IE Enhanced Security (located at Local Server properties in the Server Manager). And enable downloads in Internet Explorer security. This fixed the prerequisites installer for me.

It's a bug in the prerequisites bootstrapper on windows server 2016+.  Install .NET 3.5 through server manager (or powershell) (and specify the sxs location) manually. Then run the prerequisite bootstrapper again.  If it still doesn't work, install the remaining required server features the same way, then try again.

The following issue is being closed due to the age. If this is still an issue, please re-submit this. Thank you.
#please-close


changing the font-family for form elements

Hey,
shouldn't the font family as declared here:
https://github.com/twitter/bootstrap/blob/master/less/forms.less#L51
be $baseFontFamily?
i don't understand why there's a strict fallback to the helvetica typography...
thanks.

Resolved in 2.0.2-wip.


docker-compose up failed

Attempting to run the docker-composer up but i am getting error
 => CACHED [3/8] RUN wget --quiet -O - https://www.postgresql.org/media/keys/ACCC4CF8.asc | apt-key add -                                                                                0.0s
 => ERROR [4/8] RUN apt-get update && apt-get install -y --no-install-recommends   postgresql-client-9.6 postgis &&   apt-get autoremove -y --purge &&   apt-get clean && rm -rf /var/lib/apt  41.7s
------
 > [4/8] RUN apt-get update && apt-get install -y --no-install-recommends   postgresql-client-9.6 postgis &&   apt-get autoremove -y --purge &&   apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*:
#6 2.236 Ign http://apt.postgresql.org jessie-pgdg InRelease
#6 2.449 Ign http://apt.postgresql.org jessie-pgdg Release.gpg
#6 2.552 Get:1 http://security.debian.org jessie/updates InRelease [44.9 kB]
#6 2.702 Ign http://apt.postgresql.org jessie-pgdg Release
#6 2.711 Ign http://deb.debian.org jessie InRelease
#6 3.347 Get:2 http://deb.debian.org jessie Release.gpg [1652 B]
#6 3.347 Err http://apt.postgresql.org jessie-pgdg/main amd64 Packages
#6 3.347
#6 3.474 Get:3 http://deb.debian.org jessie Release [77.3 kB]
#6 3.546 Err http://apt.postgresql.org jessie-pgdg/main amd64 Packages
#6 3.546
#6 3.958 Err http://apt.postgresql.org jessie-pgdg/main amd64 Packages
#6 3.958
#6 3.995 Get:4 http://security.debian.org jessie/updates/main amd64 Packages [992 kB]
#6 4.262 Err http://apt.postgresql.org jessie-pgdg/main amd64 Packages
#6 4.262
#6 4.541 Err http://apt.postgresql.org jessie-pgdg/main amd64 Packages
#6 4.541   404  Not Found [IP: <IP_ADDRESS> 80]
#6 4.711 Get:5 http://deb.debian.org jessie/main amd64 Packages [9098 kB]
#6 41.64 Fetched 10.2 MB in 39s (256 kB/s)
#6 41.64 W: Failed to fetch http://apt.postgresql.org/pub/repos/apt/dists/jessie-pgdg/main/binary-amd64/Packages  404  Not Found [IP: <IP_ADDRESS> 80]
#6 41.64
#6 41.64 E: Some index files failed to download. They have been ignored, or old ones used instead.
------
executor failed running [/bin/sh -c apt-get update && apt-get install -y --no-install-recommends   postgresql-client-9.6 postgis &&   apt-get autoremove -y --purge &&   apt-get clean && rm -rf /var/lib/apt/lists/* /tmp/* /var/tmp/*]: exit code: 100
ERROR: Service 'loader' failed to build : Build failed

I'm guessing that error was caused by the very old Postgres binaries being taken down by the host.
I've rebuilt the Docker image completely to use Postgres 13 and PostGIS 3.0. The code is currently in the 202105 branch, now under the docker folder:
https://github.com/minus34/gnaf-loader/tree/202105/docker
The Docker build and run commands are in the xx_code_snippets.sh file. It's no longer a docker-compose up build.
FYI - the code will go to master after the May 2021 release of GNAF in a couple of weeks.


Confusing behavior of ignore-mode "download"

If ignore-mode "download" is set, the common sense expectation is non-visible articles not to exist in local cache. However, when set after the articles have already been downloaded, they remain.
This is not really a bug, but it deserves some attention. Possible solutions:

The downloaded (and invisible) articles should be deleted to match the expectation of a clean local cache (perhaps after a warning and confirmation after enabling the ignore-mode)

An additional option to deal properly with such situation. For example: ignore-mode "delete" which would do the same which "download" does plus also clean up local cache from old articles matching the killfiles.

Tested in:
 emanruse commented Dec 15, 2020

newsboat 2.21.0 - https://newsboat.org/
Copyright (C) 2006-2015 Andreas Krennmair
Copyright (C) 2015-2020 Alexander Batischev
Copyright (C) 2006-2017 Newsbeuter contributors
Copyright (C) 2017-2020 Newsboat contributors

Newsboat is free software licensed under the MIT License. (Type `newsboat -vv' to see the full text.)
It bundles:
- JSON for Modern C++ library, licensed under the MIT License: https://github.com/nlohmann/json
- optional-lite library, licensed under the Boost Software License: https://github.com/martinmoene/optional-lite
- expected-lite library, licensed under the Boost Software License: https://github.com/martinmoene/expected-lite

newsboat 2.21.0
System: Linux 5.9.12-1-default (i686)
Compiler: g++ 10.2.1 20200825 [revision c0746a1beb1ba073c7981eb09f55b3d993b32e5c]
ncurses: ncurses 6.2.20201031 (compiled with 6.2)
libcurl: libcurl/7.73.0 OpenSSL/1.1.1h-fips zlib/1.2.11 libidn2/2.3.0 libpsl/0.21.1 (+libidn2/2.3.0) libssh/0.9.5/openssl/zlib nghttp2/1.41.0 (compiled with 7.73.0)
SQLite: 3.34.0 (compiled with 3.33.0)
libxml2: compiled with 2.9.10

You're right, this option could've been more intuitive. Out of the approaches you listed, I'd prefer the second one, because it's backwards-compatible and lets people choose between keeping old items and deleting them retroactively.
Actually, the more I think about it, the more I wonder why Newsboat even has ignore-mode "display". Isn't it the same as filtering the feed? I'll have to dive into the Git history to see how this feature got developed, before I can decide what to do with it going further.

I'd prefer the second one

Agreed.

Actually, the more I think about it, the more I wonder why Newsboat even has ignore-mode "display". Isn't it the same as filtering the feed?

Yes.

Okay, so ignore-mode "display" was added in Newsbeuter 2.2 via https://github.com/newsboat/newsboat/commit/1c8b9e440c438e0a51ee0657c72f2cb903a1cc39 to fix https://code.google.com/archive/p/newsbeuter/issues/52. The discussion in that issue draws a clear analogy with filters, and even suggests using pre-defined filters for that.
At the time, apparently no-one was inconvenienced by ignore-mode "download" not removing articles that are already in the cache.
I think it's fine to add ignore-mode "delete" (name subject to bikeshedding still), so I'm re-labelling this as an enhancement.

Sounds good.


I18n for CouponType

Related to #82.
Like BusinessCategory, CouponType should be an instance of I18n.
Then we can use key and label on template file as well as frontend/src/pug/storeUser_store_edit.pug does.
This changes also makes codes more type safe.

I'll do this.


Change the return value of the result.get_value method

Codecov Report

Merging #10 (c2cc69b) into master (678b0be) will decrease coverage by 0.63%.
The diff coverage is 66.66%.

@@            Coverage Diff             @@
##           master      #10      +/-   ##
==========================================
- Coverage   86.32%   85.68%   -0.64%
==========================================
  Files           7        7
  Lines        1060     1062       +2
==========================================
- Hits          915      910       -5
- Misses        145      152       +7

Flag
Coverage Δ

unittests
85.68% <66.66%> (-0.64%)
:arrow_down:

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

Impacted Files
Coverage Δ

src/result.c
84.47% <66.66%> (-4.21%)
: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 678b0be...c2cc69b. Read the comment docs.


feat(Noita): add perk and knowledge orb info

Not yet a full list, but will get there eventually

I don't think that essences and curse of greed count towards perk progress as they are not on perk progress screen, but you can leave them.
Also change noita.fandom.com to noita.wiki.gg as it has more up-to-date information and more actively maintained.


Let alarms trigger at end of jobset.py instead of clearing them

Since the introduction of clearing alarms, there has been an issue with timing out tests. This will let the alarm trigger instead of clearing the alarm because an alarm handler from another process may pick up the alarm clear signal.

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

bins/opt/json_run_localhost --scenarios_json '{"scenarios": [{"name": "cpp_protobuf_sync_streaming_from_server_qps_unconstrained_secure", "warmup_seconds": 0, "benchmark_seconds": 1, "num_servers": 1, "server_config": {"async_server_threads": 0, "channel_args": [{"str_value": "throughput", "name": "grpc.optimization_target"}], "security_params": {"use_test_ca": true, "server_host_override": "foo.test.google.fr"}, "threads_per_cq": 0, "server_type": "SYNC_SERVER"}, "num_clients": 0, "client_config": {"security_params": {"use_test_ca": true, "server_host_override": "foo.test.google.fr"}, "channel_args": [{"str_value": "throughput", "name": "grpc.optimization_target"}], "async_client_threads": 0, "outstanding_rpcs_per_channel": 16, "rpc_type": "STREAMING_FROM_SERVER", "payload_config": {"simple_params": {"resp_size": 0, "req_size": 0}}, "client_channels": 64, "threads_per_cq": 0, "load_params": {"closed_loop": {}}, "client_type": "SYNC_CLIENT", "histogram_params": {"max_possible":<PHONE_NUMBER>0.0, "resolution": 0.01}}}]}' GRPC_POLL_STRATEGY=epoll1

This test times out instead of hangs. This change fixes the issue I was targetting. I'll keep an eye out on performance to see if it starts to hang again after this is merged.

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

@apolcyn - can you confirm this still fixes the timeout issue you had in your PR?
@nicolasnoble @dgquintas - friendly ping for review

yes I'm seeing this work locally, thanks

[trickle] No significant performance differences

[microbenchmarks] No significant performance differences

I'll keep an eye out on our perf benchmarking tests, but this should stop our builds from lasting hours longer than they should.
Issues:
Asan C++ - #12111
Linux dbg -  #12510
Linux opt - #12313
MacOS - #12138


Smarter auto-inference for JavaScript only repos

In some cases, we can still run into the problem where the current auto-inferred tsconfig.json doesn't actually index any JS files. Here's an auto-indexing log showing that:
+ '[' -n 2048 ']'
+ export NODE_OPTIONS=--max-old-space-size=2048
+ NODE_OPTIONS=--max-old-space-size=2048
+ scip-typescript index --infer-tsconfig
error: no files got indexed. To fix this problem, make sure that the TypeScript projects ["/data"] contain input files or reference other projects.

Can we be smarter in inferring the tsconfig.json to avoid this in more cases?

I would definitely appreciate a fix here!


Fix chaining issue in openxr_load_properties()

Looking through this chain, it seems like it converges on .foveated_varjo from two directions:

The normal chain from .system down, ending with a link from .foveated_varjo to .color_space_fb
A chain from the bottom of this list, from .space_warp_fb up through to .foveated_varjo

.space_warp_fb doesn't appear to be chained to anything, so, as far as I can tell, this chain seems like it won't be passed into the xrGetSystemProperties call.
Please let me know if I'm reading this wrong or missing something! I don't have a headset with me that might resolve any of these, so I'm currently unable to test the actual resolution. I should be able to test on Tuesday though!

Yeah, this is definitely a bug, thanks for catching this one! I did test this on a device, and was indeed seeing good results.
I think in the future I'll switch this over to this kind of pattern, which should hold up a lot better, less error prone:
result.hand_tracking.next = result.system.next; result.system.next = &result.hand_tracking;
result.hand_mesh    .next = result.system.next; result.system.next = &result.hand_mesh;


Update PrototypeBoards.md (#1594)

It looks like Silicom is now owner of MinnowBoard’s and https://minnowboard.org no longer exists

Docs Build status updates of commit a872ff6:
:white_check_mark: Validation status: passed

File
Status
Preview URL
Details

windows-iotcore/tutorials/quickstarter/PrototypeBoards.md
:white_check_mark:Succeeded

For more details, please refer to the build report.
Note: Broken links written as relative paths are included in the above build report. For broken links written as absolute paths or external URLs, see the broken link report.
For any questions, please:Try searching in the Docs contributor and Admin GuideSee the frequently asked questionsPost your question in the Docs support channel


DALY BMS (k-type) support for ESPHOME ?

Unfortunately I couldn't find where else to write, so I'm writing to a similar project.
Please make DALY BMS (k-type) support for ESPHOME. Home assistant has a working project (https://github.com/patman15/BMS_BLE-HA) - but it's only for HA, and I'd like to use it together with OpenHab.

Do you have a working setup? So your BMS is accessible via BLE and you could provide some testing?