semvec/pypi-packages huggingface dataset:
sbuuid 0.2.1
A package to generate globally unique IDs
Requires Python: >=3.6

# SBUUID Package

This package provides a way to generate globally unique ID strings.

## Installation

You can install the package via pip:

```python
pip install sbuuid
```


## Usage

```python
from sbuuid import generate_uuid

print(generate_uuid())  # Outputs a unique ID string
```
stats-calculator 1.0.0
A simple package for calculating mean and standard deviation
Requires Python: >=3.6

# Stats Calculator

A simple Python package for calculating the mean and standard deviation of a set of numbers.

## Installation

```sh
pip install stats_calculator

from stats_calculator import calculate_mean, calculate_std_dev

numbers = [1, 2, 3, 4, 5]

# Calculate the mean
mean_result = calculate_mean(numbers)
print(mean_result)  # Output: 3

# Calculate the standard deviation
std_dev_result = calculate_std_dev(numbers)
print(std_dev_result)  # Output: approximately 1.41421 (depending on precision)
lgwwhu 3.0.0
Lensing gravitational waves
Requires Python: >=3.6

调用方法1




import lgwwhu

import warnings
warnings.filterwarnings("ignore", "Wswiglal-redir-stdio")
import lal

from bilby.gw.conversion import redshift_to_luminosity_distance

from lgwwhu.main import gravitational_lens_with_amplification 
from lgwwhu.main import generate_waveform
from lgwwhu.main import compute_lensed_waveform
import matplotlib.pyplot as plt


# 计算距离
def lumDis(z):
    """
    in Mpc
    """
    return redshift_to_luminosity_distance(redshift=z)


# 生成 lens_params 参数
lens_params = {
    'ml': 1e9,              # 镜质量 (太阳质量)
    'beta': 2.5e-5,         # 入射角 (弧度)
    'zs': 2.0,              # 背景源红移
    'zl': 1.0,              # 镜红移
    'lens_model': 'point-mass'  # 透镜模型
}

# 生成 waveform_params 参数
waveform_params = {
    'approximant': 'IMRPhenomD',  # 波形近似模型
    'mass1': 50000,                  # 第一个天体的质量 (太阳质量)
    'mass2': 40000,                  # 第二个天体的质量 (太阳质量)
    'distance': lumDis(lens_params['zs']),  # 距离 (Mpc)，使用 lens_params 的 zs
    'inclination': 0              # 入射角 (弧度)
}


# 计算放大后的波形
result = compute_lensed_waveform(waveform_params, lens_params)

# 绘制结果
frequencies = result["frequencies"]
original_waveformhp = result["original_waveformhp"]
lensed_waveformhp = result["lensed_waveformhp"]
amplification = result["amplification"]


plt.figure(figsize=(10, 6))
plt.plot(frequencies, amplification.real, label="Original |hp(f)|", alpha=0.7)
plt.xlabel("Frequency (Hz)")
plt.ylabel("Amplitude")
plt.title("Lensed vs Original Frequency Domain Waveform")
plt.legend()
plt.show()



plt.figure(figsize=(10, 6))
plt.plot(frequencies, original_waveformhp.real, label="Original |hp(f)|", alpha=0.7)
plt.xlabel("Frequency (Hz)")
plt.ylabel("Amplitude")
plt.title("Lensed vs Original Frequency Domain Waveform")
plt.legend()
plt.show()

plt.figure(figsize=(10, 6))
plt.plot(frequencies, original_waveformhp.real, label="Original |hp(f)|", alpha=0.7)
plt.plot(frequencies, lensed_waveformhp.real, label="Lensed |hp(f)|", alpha=0.7)
plt.xlabel("Frequency (Hz)")
plt.ylabel("Amplitude")
plt.title("Lensed vs Original Frequency Domain Waveform")
plt.legend()
plt.show()




LIGO参数：

# 生成 lens_params 参数
lens_params = {
    'ml': 1e6,              # 镜质量 (太阳质量)
    'beta': 2.5e-5,         # 入射角 (弧度)
    'zs': 2.0,              # 背景源红移
    'zl': 1.0,              # 镜红移
    'lens_model': 'point-mass'  # 透镜模型
}

# 生成 waveform_params 参数
waveform_params = {
    'approximant': 'IMRPhenomD',  # 波形近似模型
    'mass1': 30,                  # 第一个天体的质量 (太阳质量)
    'mass2': 20,                  # 第二个天体的质量 (太阳质量)
    'distance': lumDis(lens_params['zs']),  # 距离 (Mpc)，使用 lens_params 的 zs
    'inclination': 0              # 入射角 (弧度)
}



zrj
2024-12-12
gzq_package 1.0.0
gzq_package 是一个用于LUMERICAL进行反向设计的包。

# Continuous adjoint optimization wrapper for Lumerical

## Introduction

This is a continuous adjoint opimtization wrapper for Lumerical, using Python as the main user interface. It is released under an MIT license. It is still work in progress 
and any contribution will be very welcome! New features to come out soon, and make it even easier to use (hopefully)!

If you use this tool in any published work, please cite https://www.osapublishing.org/oe/abstract.cfm?uri=oe-21-18-21693 and give a link to this repo. Thanks!

## Tutorials, Examples, and Documentation

It is all here: https://lumopt.readthedocs.io/en/latest/

## Install

Make sure you have Python 3 and the latest version of Lumerical installed (it won't work correctly with older versions), and that lumapi (the python api) works.

```bash
cd your/install/folder/
git clone https://github.com/chriskeraly/LumOpt.git
python setup.py develop
```

I would strongly recommend using jupyter notebooks to run optimizations.

## First optimization

If you are not using jupyter notebooks:

```bash
cd your/install/folder/examples/Ysplitter
python splitter_opt_2D.py
```

Otherwise copy `your/install/folder/examples/Ysplitter/splitter_opt_2D.py` into a notebook
crawler-update-detector 1.0.1
a test package
Requires Python: >=3.8

# easytest
`easytest`是一个接口自动化框架。

功能特点：

- 支持http接口测试
- 支持`json`，`html`,`xml`格式的响应断言
- 支持数据库断言
- 支持用例标记筛选
- 支持用例失败重运行
- 支持多线程