
Research
PyPI Package Disguised as Instagram Growth Tool Harvests User Credentials
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.
Feature selector based on Thompson sampling algorithm Based on: https://epubs.siam.org/doi/pdf/10.1137/1.9781611976700.36
This package is used to select optimal subset of features to maximize selected metric. Optimization could be used for both regression and classification.
import pandas as pd
import numpy as np
from sklearn.datasets import make_regression
from sklearn.metrics import make_scorer
from sklearn.metrics import mean_absolute_error
from sklearn.linear_model import LinearRegression
from mabfs.ts_selector import ThompsonSamplingFeatureSelection
x, y, coef = make_regression(n_samples=1000,
n_features=500,
n_informative=10,
effective_rank=5,
tail_strength=0.7,
noise=0.05,
shuffle=True,
bias=100,
coef=True,
random_state=666)
x = pd.DataFrame(x)
y = pd.Series(y)
true_features = np.where(coef > 0)[0]
model = LinearRegression()
tsfs = ThompsonSamplingFeatureSelection(model=model,
scoring=make_scorer(mean_absolute_error),
desired_number_of_features=10,
x=x,
y=y,
cv_splits=3,
exploration_coef=0.3,
optimization_steps=100000,
is_regression=True,
n_jobs=36
)
tsfs.select_best_features()
FAQs
Multi armed bandit feature selection
We found that mabfs demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
A deceptive PyPI package posing as an Instagram growth tool collects user credentials and sends them to third-party bot services.
Product
Socket now supports pylock.toml, enabling secure, reproducible Python builds with advanced scanning and full alignment with PEP 751's new standard.
Security News
Research
Socket uncovered two npm packages that register hidden HTTP endpoints to delete all files on command.