Here is the list of hyperparameters that I used: params = { 'scale_pos_weight': [1.0], 'eta': [0.05, 0.1, 0.15, 0.9, 1.0], 'max_depth': [1, 2, 6, 10, 15, 20], 'gamma': [0.0, 0.4, 0.5, 0.7] } The dataset is imbalanced so I used scale_pos_weight parameter. After 5 fold cross validation the f1 score that I got is: 0.530726530426833
I am working on a project which involves developing a machine learning/deep learning for an application in a roll-to-roll industry. For a long time, I have been looking for similar problems as a way to get some guidance but I was never able to find anything related. Basically, the problem can be seen as follows: An industrial machine is producing a roll of some material, which tends to have visible defects throughout the roll. I have already available a machine …
How would I retrieve attachments from all subpages of a specific Page ID? Example: SPECIFIC PAGE Child (with attachments) Child (with attachments) Child (with attachments) I'm currently using this code to retrieve all attachments site-wide, however I would like to limit this to only pull images from all children of a specific Page. $args = array( 'post_type' => 'attachment', 'numberposts' => -1, 'post_status' => null, 'post_parent' => null ); $attachments = get_posts( $args ); if ( $attachments ) { foreach …
I have a JSON file (tweets.json) that contains tweets (sentences) along with the name of the author. Objective 1: Get the most frequent entities from the tweets. Objective 2: Find out the sentiment/polarity of each author towards each of the entities. Sample Input: Assume we have only 3 tweets: Tweet1 by Author1: Pink Pearl Apples are tasty but Empire Apples are not. Tweet2 by Author2: Empire Apples are very tasty. Tweet3 by Author3: Pink Pearl Apples are not tasty. Sample …
Used a RandomForestClassifier for my prediciton model. But the output printed is either 0 or in decimals. What do I need to do for my model to show me 0 and 1's instead of decimals? Note: used feature importance and removed the least important columns,still the accuracy is the same and the output hasn't changed much. Also, i have my estimators equal to 1000. do i increase or decrease this? edit: target col 1 0 0 1 output col 0.994 …
I'm fairly new to machine learning and I'm aware of the concept of hyper-parameters tuning of classifiers, and I've come across a couple of examples of this technique. However, I'm trying to use NaiveBayes Classifier of sklearn for a task but I'm not sure about the values of the parameters that I should try. What I want is something like this, but for GaussianNB() classifier and not SVM: from sklearn.model_selection import GridSearchCV C=[0.05,0.1,0.2,0.3,0.25,0.4,0.5,0.6,0.7,0.8,0.9,1] gamma=[0.1,0.2,0.3,0.4,0.5,0.6,0.7,0.8,0.9,1.0] kernel=['rbf','linear'] hyper={'kernel':kernel,'C':C,'gamma':gamma} gd=GridSearchCV(estimator=svm.SVC(),param_grid=hyper,verbose=True) gd.fit(X,Y) print(gd.best_score_) print(gd.best_estimator_) …
I have a dataset that contains some user-specific detials like gender, age-range, region etc. and also the behavioural data which contains the historical click-through-rate (last 3 months) for different ad-types shown to them. Sample of the data is shown below. It has 3 ad-types i.e. ecommerce, auto, healthcare but the actual data contains more ad-types. I need to build a regression model using XGBRegressor that can tell which ad should be shown to a given new user in order to …
I've a few post that have ACF relationship field set up : - Post A - Post A1 - Post A2 - Post A3 Post A have a relationship that link to : Post A1,A2 & A3... Post A1,A2,A3 have their own post templates, But inside the post templates, can I manage to get Post A's Title? Because I don't want hardcoded Post A's title on Post A1,A2,A3's fields. I'd tried this solution, but seems can't retrieve parent A's post …
I want to plement a model of neural network using sckitlearn . and I want to know which activation function should I use ? I have 10 input variable and one output . all variable are floats(positive ). and the Output is a pecentage ( 0 to 100). and my model is note linear to the output variable, so i'll creat regression model with one hidden layer!!
I have a dataset and would like to train CNNs on subsets of different size of the dataset. I already have a CNN, which classifies very well if I use the entire dataset. Now the question arises if I should really try to additionally optimize the parameters of the CNN for the subsets, regardless of whether I do Data Augmentation or not? Does it really make sense if I try to change the CNN model for the subsets by using …
My media items are not stored in YYYY/MM subfolders of uploads. Instead, I had cooked up some scheme to ingest posts, but seem to have declined/neglected to organise them that way. So, I've got a combination of one big uploads folder containing thousands of files, plus some specific subfolders in uploads, like logos, people, icons. That's because not everything is related to a post. But the images that do relate to posts... well, they are disorganised. I think I wish …
I stumbled upon different sources that state that each sentence starts with a CLS token when passed to BERT. I'm passing text documents with multiple sentences to BERT. This would mean that for each sentence, I would have one CLS token. Pooled output is however only returning a vector of size hidden state. Does this mean that all CLS tokens are somehow compressed to one (averaging?)? Or does my text document only contain one single CLS token for the whole …
I've been coder for decades but I need to setup some microsites super-fast. I chose WordPress as the platform and I'm complete newbie to WordPress. The behaviour I need I know can do it programming. But the question is if this can be done "zero-code" in WordPress: Question Can I bind in-page "triggers" to "actions" natively in WordPress? Examples Whenever a user scrolls more than 80%, a new button is added. Whenever a user watches an embedded video hosted in …
I'm trying to understand the architecture of the ViT Paper, and noticed they use a CLASS token like in BERT. To the best of my understanding this token is used to gather knowledge of the entire class, and is then solely used to predict the class of the image. My question is — why does this token exist as input in all the transformer blocks and is treated the same as the word / patches tokens? Treating the class token …
The swish/SiLU activation is very popular, and many would argue it has dethroned ReLU. However, it is non-monotonic, which seems to go against popular intuition (at least on this site: example 1, example 2). Reading the swish paper, the justification that the authors give is that non-monotonicity "increases expressivity and improves gradient flow... [and] may also provide some robustness to different initializations and learning rates." The authors provide an image to back up this claim, but at best this argument …
I am trying to implement a Plackett-Luce model for learning to rank from click data. Specifically, I am following the paper: Doubly-Robust Estimation for Correcting Position-Bias in Click Feedback for Unbiased Learning to Rank. The objective function is the reward function similar to the one used in reinforcement learning $R_d$ is the reward for document d, $\pi(k \vert d)$ is the probability of document d placed at position k for a given query q. $w_k$ is the weight of position …
I have three drop-down list in cascade, I'm using the code of Ján Bočínec but it working just the first level when I choose the grade it not work, should enable the third drop-down list and show the groups. I see that the jQuery('#parent_grado').change is not working, I don't know if is because is created dynamically. Can you please help me to find the bug or advice me if is possible the way that I try to created the web …
In 'Automatic construction of lexicons, taxonomies, ontologies, and other knowledge structures' they have mentioned; There are two slightly different classes of measure: lexical cohesion (sometimes called ‘unithood’ or ‘phraseness’), which quantifies the expectation of co-occurrence of words in a phrase (e.g., back-of-the-book index is significantly more cohesive than term name); and semantic informativeness (sometimes called ‘termhood’), which highlights phrases that are representative of a given document or domain. However, the review does not include the ways to calculate/derive these measures. …
I have the following problem when I am validating a field with the Advanced Custom Fields plugin in wordpress. What happens is that the field is validated correctly but the error appears on a new page instead of going out on the same page above the field to which I am validating. The code to validate is the following: function validate_fields_contact() { add_filter('acf/validate_value/name=phone_contact', 'validate_phone_number', 10, 4); } function validate_phone_number($valid, $value, $field, $input) { if (!$valid) { return $valid; } if(!preg_match("/^\+XX(\s|\d){8,12}$/", …
I'm trying to set a default variation for each product so I wouldn't need to set it manually on each product separately through the admin panel. I tried to insert the code below but it doesn't work. I'm using Variation Swatcher for WooCommerce plugin as well but from analyzing the DB it shouldn't cause the issue. My code: function setting_product_default_attributes() { global $product; if (!count($default_attributes = get_post_meta($product->get_id(), '_default_attributes'))) { $new_defaults = array(); $product_attributes = $product->get_attributes(); if (count($product_attributes)) { foreach ($product_attributes …
I'm trying to translate a plugin, Dokan Pro, but I can't seem to find the correct .po file that my Wordpress site is using to translate. Part of it is already translated in Italian, but other parts are still in English. I've tried by placing the .po and .mo file for the plugin, named correctly as per documentation (dokan-it_IT and dokan-lite-it_IT) in the /wp-content/languages/plugins directory, but it won't take that files. Is there any other .po files from where it …
I'm attempting to train a spaCy model for the purposes of computing semantic similarity but I'm not getting the results I would anticipate. I have created two text files that contain many sentences that use a new term, "PROJ123456". For example, "PROJ123456 is on track." I've added each to a DocBin and saved them to disk as train.spacy and dev.spacy. I'm then running: python -m spacy train config.cfg --output ./output --paths.train ./train.spacy --paths.dev ./dev.spacy The config.cfg file contains: [paths] train …
I am trying to create a regression model that predicts the box office success of a movie, with one of the explanatory variables being the actors who appear in the film. My problem is that I decided to do the first 4 billed actors, but in the model, it is taking it as 4 separate variables (Actor 1, Actor 2, Actor 3, Actor 4). For example, Jack Nicholson is the lead in "as good as it gets" so he would …
Is it possible to add nonce tag to inline scripts for wordpress sites using ? I have used a filter script_loader_tag + function for adding tags before but it adds nonce tag only to with src tag. Unfortunately I cant add nonce tag to inline javascript automatically :( So I need a script for some filter which would add nonce tag automatically to tag.
I have author page on my website: https://inwestujfinanse.pl/author/admin/ when I try to change it normally in https://inwestujfinanse.pl/wp-admin/profile.php nothing happens. Is there any way I can change it in the database or something? I don't want to install any additional plugin. Please help me.
I'm using a plugin - "cleverness-to-do-list" (https://wordpress.org/plugins/cleverness-to-do-list/#description ). I'm aware that the plugin is closed, but I've updated it at my end and gotten it working with my self-hosted Wordpress edition (version 6). I'm trying to create a setup where a remote server calls a webpage on my server and POSTs some data. That custom PHP webpage is configured to create a new ToDo item (which is placed in the posts table). It does that fine except for setting the …
In my wp-config.php file, I have the line: define('DISALLOW_FILE_EDIT', true); I always include this on all sites as standard, and it's always worked exactly as expected. However, I've only just noticed that on one client's site, it has stopped working. They have the User Role Editor plugin that was set up to define a handful of custom roles. Once the roles were set up, the plugin was deactivated (it doesn't need to be active for the roles to exist) and …
My weights are store in a two dimensional matrix. Row i refers to node i in preceding layer and columns in that row are the neurons node i is connected to. I only want to keep some nodes. How do I pick 3 max weights and store it in a separate array while keeping track of which neuron it belonged to. Moreover, is it tested in theory that some weights contribute more than the others?
Below are my questions of R-Squared for real valued label under non linear regression learner. It may be a large problem, if there is no easy answer, could you give me some references? Firstly for the real valued label, except for R-squared, is there any good value to evaluate the performance of fitting? I know that small MSE, MAE, e.t.c usually mean the good fitting. However they may be not as intuitive as a ratio like R-Sqaured (how small is …
I have increased height of navbar and customized logo size and position to center. After increasing height, half of the slider gets hidden behind the navigation bar. here is the website. https://almashier.com/ I tried adding some padding between slider and navbar but The header is sticky and adjusts height on scroll which causes gap on scroll.
Hi I have now managed to plot various points on a map and interpolate with ordinary kriging. However, my data does not look anything like it should. Do I need to use an algorithm to fill in the missing data? Does anyone know how the RCWIP2 model does this? My data looks like this: and it should look like this: https://www.researchgate.net/figure/Global-mean-annual-average-leaf-water-d-18-O-and-d-2-H-isoscapes-for-the-sites-of_fig1_226462314 Does anyone have an idea where to get an algorythm (open source) for this? Or is it possible to …
Ok here we go. I have 2 different custom post types. The first is called 'portfolio', the second one 'games'. All the game reviews I write are 'games' posts. To have a better overview I created custom categories like reviews, playstation xbox etc. Unfortunately everytime I would like to display the posts of one categorie (http://www.zock-around-the-clock.com/games_category/testcategory) I just get an 404 Error Page. I dont really use the 'portfolio' posts but with them the arrengement into categories would work just …
I have a heatmap image (correlation between all matrix columns) and I'm straggling to preform all the changes below within the same image: bar colors should be symmetric around zero (e.g., correlation of 1 and -1 should be with the same color) change the correlation matrix to a diagonal matrix, since correlation values are symmetric - and show only upper matrix triangle (mask out the lower triangle ) show the correlation values in every cell of the diagonal matrix x,y …